Skip to content

Regression in 5 crates in 1.26: the trait bound is not satisfied #49932

Closed

Description

@emilyalbini

There are a few crates that are failing to build on Rust 1.26 with the error the trait bound '###' is not satisfied. A lot of those errors seems to be related with !.

Activity

  1. added
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    C-bugCategory: This is a bug.
    on Apr 13, 2018
  2. added this to the 1.26 milestone on Apr 13, 2018
  3. mackwic commented on Apr 13, 2018

    @mackwic
    Contributor

    thanks for the notification @pietroalbini ! Can I have the error log for rspec ?

  4. emilyalbini commented on Apr 13, 2018

    @emilyalbini
    MemberAuthor

    Woops! Forgot to add the link for that crate. Thanks for pointing that out! rspec report

  5. mackwic commented on Apr 13, 2018

    @mackwic
    Contributor

    What is even ! ? I don't understand this error 😕

  6. emilyalbini commented on Apr 13, 2018

    @emilyalbini
    MemberAuthor

    What is even ! ? I don't understand this error 😕

    The ! type is the "never" type, specified in RFC 1216 and stabilized in 1.26. It basically means "this return value is unreachable". In your case, that's the value returned by panic!.

  7. Mark-Simulacrum commented on Apr 13, 2018

    @Mark-Simulacrum
    Member

    Errors related to ! might not be worth fixing just yet as I believe we're planning to revert that stabilization.

  8. acmcarther commented on Apr 13, 2018

    @acmcarther
    Contributor

    cucumber crate author here:

    I wasn't able to replicate this from what I gleamed in the linked logs:

    $ git clone git@github.com:acmcarther/cucumber && cd cucumber
    $ rustup toolchain install beta-2018-04-06-x86_64-unknown-linux-gnu 
    $ rustup default beta-2018-04-06-x86_64-unknown-linux-gnu
    $ CARGO_INCREMENTAL=0 RUST_BACKTRACE=full RUSTFLAGS=--cap-lints=warn cargo test --no-run --frozen
    # Build succeeds
    

    Absent an actual reproduction though, I suspect dropping return from my return panic will probably resolve the issue in my crate.

  9. hawkw commented on Apr 13, 2018

    @hawkw
    Contributor

    We're also seeing this when buillding h2 against nightly: hyperium/h2#257.

  10. emilyalbini commented on Apr 20, 2018

    @emilyalbini
    MemberAuthor

    This will be fixed after #50121 (reverting the stabilization) is merged and backported into beta.

  11. emilyalbini commented on Apr 24, 2018

    @emilyalbini
    MemberAuthor

    The stabilization of ! is now reverted both on beta and nightly. Sorry for the trouble!

  12. emilyalbini commented on May 1, 2018

    @emilyalbini
    MemberAuthor

    A lot of those errors seems to be related with !.

    Well, apparently not all of the errors in this issue were related to the never type. plexus 0.0.1 (not the latest version) is still failing on the latest beta (with the stabilization rollback backported):

     error[E0277]: the trait bound `u64: graph::geometry::Geometry` is not satisfied
       --> /.../plexus-0.0.1/src/graph/mesh.rs:90:1
        |
     90 | / pub struct Mesh<G = u64>
     91 | | where
     92 | |     G: Geometry,
     93 | | {
     ...  |
     96 | |     pub(super) faces: Storage<FaceKey, Face<G::Face>>,
     97 | | }
        | |_^ the trait `graph::geometry::Geometry` is not implemented for `u64`
        |
     note: required by `graph::geometry::Geometry`
       --> /.../plexus-0.0.1/src/graph/geometry/mod.rs:8:1
        |
     8  | pub trait Geometry: Sized {
        | ^^^^^^^^^^^^^^^^^^^^^^^^^
    

    Build log

  13. emilyalbini commented on May 1, 2018

    @emilyalbini
    MemberAuthor

    Bisected the plexus thing, the regression is caused by #46785, cc @leodasvacas @nikomatsakis

  14. leoyvens commented on May 1, 2018

    @leoyvens
    Contributor

    That's intended, G can never be u64 making the default unusable so we error. Given that crater was clean at the time of the change and that plexus, the only known affected crate, is only affected on a very old version I see no reason to revert or alleviate the change. Thanks for the bisect and ping!

  15. nikomatsakis commented on May 1, 2018

    @nikomatsakis
    Contributor

    That version of plexus seems to have no dependencies:

    https://crates.io/crates/plexus/reverse_dependencies

    There is a dependency on 0.0.1 from the bismuth crate -- cc @olson-sean-k, you may want to update to a newer version of plexus. =)

  16. emilyalbini commented on May 1, 2018

    @emilyalbini
    MemberAuthor

    Ok, I'll close this issue back.

  17. olson-sean-k commented on May 1, 2018

    @olson-sean-k
    Contributor

    Thanks for the ping! Sorry I've been absent from the discussion.

    There is a dependency on 0.0.1 from the bismuth crate ... you may want to update to a newer version of plexus. =)

    Yep, bismuth fails to build here because it depends on plexus at 0.0.1 and exhibits that error. I'll go ahead and publish a new version of bismuth to pull in updated dependencies. :-)

  18. nikomatsakis commented on May 2, 2018

    @nikomatsakis
    Contributor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions