-
Notifications
You must be signed in to change notification settings - Fork 180
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
Panic while formatting date in beta and nightly compilers #5039
Comments
I'm surprised this wasn't caught by our CI The test I've been using to check this is
|
@robertbastian would you be able to verify why the nightly CI didn't catch this? |
in both scheduled CI jobs https://github.com/unicode-org/icu4x/actions/runs/9501131062/job/26185924275 , https://github.com/unicode-org/icu4x/actions/runs/9501092498/job/26185787376 I know we tweaked how the nightly toolchain got set a bunch of times, I suspect we broke it? |
Fixes unicode-org#5039 Caused by rust-lang/rust#125360. We were assuming that `packed` meant `C, packed` already. This is an assumption I've seen throughout the Rust ecosystem so there may be reasons to revert.
Fixes unicode-org#5039 Caused by rust-lang/rust#125360. We were assuming that `packed` meant `C, packed` already. This is an assumption I've seen throughout the Rust ecosystem so there may be reasons to revert.
Fixes unicode-org#5039 Caused by rust-lang/rust#125360. We were assuming that `packed` meant `C, packed` already. This is an assumption I've seen throughout the Rust ecosystem so there may be reasons to revert.
Fixes unicode-org#5039 Caused by rust-lang/rust#125360. We were assuming that `packed` meant `C, packed` already. This is an assumption I've seen throughout the Rust ecosystem so there may be reasons to revert.
Fixes unicode-org#5039 Caused by rust-lang/rust#125360. We were assuming that `packed` meant `C, packed` already. This is an assumption I've seen throughout the Rust ecosystem so there may be reasons to revert.
June 27
LGTM: @sffc, @robertbastian , @Manishearth |
Tracking rustsec |
The following code panics while handling a panic in beta and nightly versions of Rust:
main.rs:
cargo.toml
output:
(library\core\src\fmt\mod.rs:2431:38)
It's not really easy to debug, but it seems like the original panic is because of this debug_assert failing and the next panic seems to happen while trying to format
icu_calendar::Era
- so the original error was probablyDateTimeWriteError::MissingEraSymbol
. In release mode, this causes invalid UTF-8 to be written, because the era is wrong (from debugging I noticed it seems to be garbage - at least until the next nul).test_japanese
panics on nightly as well (when changing the toolchain inrust-toolchain.toml
to nightly).Update: It seems like rustc decided to swap the order of the tuple elements inside
dates_to_eras
, so it thinks the string comes first, but that one doesn't contain valid UTF-8.The text was updated successfully, but these errors were encountered: