Description
Code
I don't have a minimal example yet, but here's the code. Sample:
async fn report_check_interval(&mut self, install_source: InstallSource) {
let now = self.time_source.now();
match self.context.schedule.last_update_check_time {
Some(PartialComplexTime::Wall(t)) => match now.wall_duration_since(t) {
Ok(interval) => self.report_metrics(Metrics::UpdateCheckInterval {
interval,
clock: ClockType::Wall,
install_source,
}),
Err(e) => warn!("Last check time is in the future: {}", e), // <-- ICE
},
Some(PartialComplexTime::Complex(t)) => match now.mono.checked_duration_since(t.mono) {
Some(interval) => self.report_metrics(Metrics::UpdateCheckInterval {
interval,
clock: ClockType::Monotonic,
install_source,
}),
None => error!("Monotonic time in the past"), // <-- ICE
},
_ => {}
}
self.context.schedule.last_update_check_time = now.into();
}
The ICE happens on the warn!
and error!
macros, which are both from the log
crate.
Meta
This began with commit 74500b9.
Error output
error: internal compiler error: failed to process buffered lint here
--> ../../src/sys/pkg/lib/omaha-client/src/state_machine.rs:539:27
|
539 | Err(e) => warn!("Last check time is in the future: {}", e),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: delayed at /b/s/w/ir/x/w/rust/compiler/rustc_lint/src/early.rs:384:18
= note: this error: internal compiler error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
error: internal compiler error: failed to process buffered lint here
--> ../../src/sys/pkg/lib/omaha-client/src/state_machine.rs:552:25
|
552 | None => error!("Monotonic time in the past"),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: delayed at /b/s/w/ir/x/w/rust/compiler/rustc_lint/src/early.rs:384:18
= note: this error: internal compiler error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
error: internal compiler error: failed to process buffered lint here
--> ../../src/sys/pkg/lib/omaha-client/src/state_machine.rs:997:27
|
997 | Err(e) => warn!("Update first seen time is in the future: {}", e),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: delayed at /b/s/w/ir/x/w/rust/compiler/rustc_lint/src/early.rs:384:18
= note: this error: internal compiler error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
Backtrace
RUST_BACKTRACE=1 ../../prebuilt/third_party/rust/linux-x64/bin/rustc --color=always --crate-name omaha_client ../../src/sys/pkg/lib/omaha-client/src/lib.rs --crate-type rlib --emit=dep-info=obj/sr…
error: internal compiler error: failed to process buffered lint here
--> ../../src/sys/pkg/lib/omaha-client/src/state_machine.rs:539:27
|
539 | Err(e) => warn!("Last check time is in the future: {}", e),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: delayed at /b/s/w/ir/x/w/rust/compiler/rustc_lint/src/early.rs:384:18
= note: this error: internal compiler error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
error: internal compiler error: failed to process buffered lint here
--> ../../src/sys/pkg/lib/omaha-client/src/state_machine.rs:552:25
|
552 | None => error!("Monotonic time in the past"),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: delayed at /b/s/w/ir/x/w/rust/compiler/rustc_lint/src/early.rs:384:18
= note: this error: internal compiler error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
error: internal compiler error: failed to process buffered lint here
--> ../../src/sys/pkg/lib/omaha-client/src/state_machine.rs:997:27
|
997 | Err(e) => warn!("Update first seen time is in the future: {}", e),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: delayed at /b/s/w/ir/x/w/rust/compiler/rustc_lint/src/early.rs:384:18
= note: this error: internal compiler error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
thread 'rustc' panicked at 'no errors encountered even though `delay_span_bug` issued', compiler/rustc_errors/src/lib.rs:974:13
stack backtrace:
0: rust_begin_unwind
at /b/s/w/ir/x/w/rust/library/std/src/panicking.rs:493:5
1: std::panicking::begin_panic_fmt
at /b/s/w/ir/x/w/rust/library/std/src/panicking.rs:435:5
2: rustc_errors::HandlerInner::flush_delayed
3: <rustc_errors::HandlerInner as core::ops::drop::Drop>::drop
4: core::ptr::drop_in_place<rustc_session::parse::ParseSess>
5: <alloc::rc::Rc<T> as core::ops::drop::Drop>::drop
6: core::ptr::drop_in_place<rustc_interface::interface::Compiler>
7: rustc_span::with_source_map
8: rustc_interface::interface::create_compiler_and_run
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
note: rustc 1.51.0-nightly (b12290861 2021-01-29) running on x86_64-unknown-linux-gnu
note: compiler flags: -Z dep-info-omit-d-target -Z allow-features= -Z panic_abort_tests -C linker=/b/s/w/ir/x/w/fuchsia/prebuilt/third_party/clang/linux-x64/bin/lld -C link-arg=--sysroot=gen/zircon…
query stack during panic:
end of query stack