Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MSRV broken in minor version #2735

Closed
2 tasks done
TeXitoi opened this issue Aug 23, 2021 · 2 comments
Closed
2 tasks done

MSRV broken in minor version #2735

TeXitoi opened this issue Aug 23, 2021 · 2 comments
Labels
C-bug Category: Updating dependencies

Comments

@TeXitoi
Copy link
Contributor

TeXitoi commented Aug 23, 2021

Please complete the following tasks

  • I have searched the discussions
  • I have searched the existing issues

Rust Version

rustc 1.36.0 (a53f9df32 2019-07-03)

Clap Version

v2.33.3

Minimal reproducible code

fn main() {}

Steps to reproduce the bug with the above code

cargo build

Actual Behaviour

    Compiling clap v2.33.3

error[E0433]: failed to resolve: could not find `stringify` in `_core`
  --> /home/travis/.cargo/registry/src/github.com-1ecc6299db9ec823/clap-2.33.3/src/app/settings.rs:7:1
   |
7  | / bitflags! {
8  | |     struct Flags: u64 {
9  | |         const SC_NEGATE_REQS       = 1;
10 | |         const SC_REQUIRED          = 1 << 1;
...  |
51 | |     }
52 | | }
   | |_^ could not find `stringify` in `_core`
   |
   = note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)
error[E0433]: failed to resolve: could not find `stringify` in `_core`
  --> /home/travis/.cargo/registry/src/github.com-1ecc6299db9ec823/clap-2.33.3/src/args/settings.rs:6:1
   |
6  | / bitflags! {
7  | |     struct Flags: u32 {
8  | |         const REQUIRED         = 1;
9  | |         const MULTIPLE         = 1 << 1;
...  |
28 | |     }
29 | | }
   | |_^ could not find `stringify` in `_core`
   |
   = note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0433`.

Expected Behaviour

compile succeed

Additional Context

It was working with the 2.33.2, it breaks structopt MSRV

https://app.travis-ci.com/github/TeXitoi/structopt/jobs/532369433

Seems that the MRSV is not tested by the github ci in clap.

I don't really care, but I think that's better to at least document MSRV upgrade somewhere (the README says >=2.21: 1.24.0)

Debug Output

No response

@TeXitoi TeXitoi added the C-bug Category: Updating dependencies label Aug 23, 2021
@epage
Copy link
Member

epage commented Aug 23, 2021

This is coming from the bitflags crate which has its own MSRV. Having an MSRV does not mean that all dependencies are locked down to only allow the MSRV. Overly constraining dependencies for the sake of MSRV can actually be harmful, like what happened with nom

The best I can offer at the moment is to use -Z minimal-versions or for people to patch the dependency

See #2691 which had a similar issue.

@TeXitoi
Copy link
Contributor Author

TeXitoi commented Aug 23, 2021

Sure, thanks for the quick reply, and sorry for not finding the previous issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: Updating dependencies
Projects
None yet
Development

No branches or pull requests

2 participants