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

1.18.1: allow(unused) incompatible with previous forbid #271

Closed
mrtnzlml opened this issue Aug 10, 2022 · 2 comments
Closed

1.18.1: allow(unused) incompatible with previous forbid #271

mrtnzlml opened this issue Aug 10, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@mrtnzlml
Copy link

What happened?

It's all visible in the following automated PR: adeira/universe#4861

I started getting the following error:

error[E0453]: allow(unused) incompatible with previous forbid
  --> server/src/warp_server/models.rs:72:9
   |
72 | /         insta::assert_snapshot!(
73 | |             get_current_user(&pool, &Some(String::from("XYZ")))
74 | |             .await
75 | |             .err()
76 | |             .unwrap(),
77 | |              @"Unable to parse 'authorization' header (should be 'Bearer XYZ')."
78 | |         );
   | |_________^ overruled by previous forbid
   |
  ::: server/src/main.rs:3:11
   |
3  |   #![forbid(unused_must_use)]
   |             --------------- `forbid` level set here
   |
   = note: this error originates in the macro `$crate::assert_snapshot` (in Nightly builds, run with -Z macro-backtrace for more info)

For more information about this error, try `rustc --explain E0453`.

Note: my project uses #![forbid(unused_must_use)] in main.rs

Reproduction steps

Check this PR: adeira/universe#4861

Insta Version

1.18.1

rustc Version

rustc 1.62.1 (e092d0b6b 2022-07-16)

What did you expect?

no error (or just errors related to the 1.18.0 breaking changes)

@mrtnzlml mrtnzlml added the bug Something isn't working label Aug 10, 2022
@mitsuhiko
Copy link
Owner

Thank you. This is fixed on both master and in 1.18.2

@mrtnzlml
Copy link
Author

@mitsuhiko Awesome, thanks! I really appreciate that you put some effort into making the migration easy!

Screen Shot 2022-08-11 at 12 19 43

❤️ ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants