Compilation error with rust 1.51.0: "panic message is not a string literal"
Categories
(Testing :: Mozbase Rust, task)
Tracking
(firefox89 fixed)
| Tracking | Status | |
|---|---|---|
| firefox89 | --- | fixed |
People
(Reporter: kats, Assigned: kats)
References
Details
Attachments
(2 files)
STR: rustup update stable && mach build
Compilation fails with:
0:58.45 error: panic message is not a string literal
0:58.45 --> testing/mozbase/rust/mozprofile/src/prefreader.rs:258:33
0:58.46 |
0:58.46 258 | x => panic!(format!("Boolean wasn't 'true' or 'false' (was {})", x)),
0:58.46 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
0:58.46 |
0:58.46 = note: `-D non-fmt-panic` implied by `-D warnings`
0:58.46 = note: this is no longer accepted in Rust 2021
0:58.46 = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
| Assignee | ||
Comment 1•5 years ago
|
||
Apparently panic! can take format arguments directly now.
https://treeherder.mozilla.org/#/jobs?repo=try&revision=693c9d3fd7de034e03b48fb82aa18d69283e5b30
| Assignee | ||
Comment 2•5 years ago
|
||
Also https://treeherder.mozilla.org/jobs?repo=try&revision=d94295c1ed028c851b654e485fc6a4ba04898781 for a similar fix in wrench code
| Assignee | ||
Comment 3•5 years ago
|
||
| Assignee | ||
Comment 4•5 years ago
|
||
Depends on D110029
Comment 5•5 years ago
|
||
Why didn't I hit this when I tried the upgrade to 1.51.0 on try? https://treeherder.mozilla.org/jobs?repo=try&selectedTaskRun=b94XHQpmTBOzrQ7l3tbCaQ.0&revision=061bad52b004739ab1432ef0ca7594af5ca37dfc
| Assignee | ||
Comment 6•5 years ago
|
||
It looks like the relevant code is in the rust version of mozprofile, which AFAICT is only included by geckodriver and that in turn is only enabled under certain conditions which seem to exclude in automation?
| Assignee | ||
Comment 7•5 years ago
|
||
I also added a couple of wrench jobs to your try push and they failed as I would expect (this is fixed by the second patch on this bug). wrench doesn't get compiled except when running specific jobs that use it.
(In reply to Kartikaya Gupta (email:kats@mozilla.staktrace.com) from comment #6)
It looks like the relevant code is in the rust version of mozprofile, which AFAICT is only included by geckodriver and that in turn is only enabled under certain conditions which seem to exclude in automation?
The geckodriver build jobs are toolchain jobs and run separate from the build ones. You can find them in Treeherder as gd. Note that I'm going to add a new geckodriver preset for try via bug 1700454 so that it makes it easier to include all relevant jobs.
Comment 9•5 years ago
|
||
I'm going to go ahead and trigger lando for part 1 here, to reduce potential for dupes cropping up while we're waiting for part 2.
(This morning I independently noticed & filed & posted a patch for the "part 1" warning, over in bug 1701700.)
Comment 10•5 years ago
|
||
| Assignee | ||
Comment 12•5 years ago
|
||
Feel free to also r+/lando on part 2, it's pretty trivial
Comment 13•5 years ago
|
||
I tagged nical as an alternate reviewer on phabricator; hopefully he or kvark can r+ and trigger lando soonish.
Comment 14•5 years ago
|
||
Comment 15•5 years ago
|
||
| bugherder | ||
| Assignee | ||
Updated•5 years ago
|
Description
•