Skip to content

Clippy fails to compute type ("failed to lookup SourceFile in new context") #8164

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

Closed
emmiegit opened this issue Dec 24, 2021 · 3 comments
Closed
Labels
I-ICE Issue: Clippy panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@emmiegit
Copy link

This GitHub workflow is failing with the following:

Run cd deepwell && cargo clippy
   Compiling deepwell v0.3.0 (/home/runner/work/wikijump/wikijump/deepwell)
thread 'rustc' panicked at 'failed to lookup `SourceFile` in new context', compiler/rustc_query_impl/src/on_disk_cache.rs:500:22
note: run with `RUST_BACKTRACE=1` environment variable to display a 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-clippy/issues/new

note: Clippy version: clippy 0.1.59 (c09a952 2021-12-23)

query stack during panic:
#0 [type_of] computing type of `web::ratelimit::GovernorMiddleware::limiter`
#1 [inferred_outlives_crate] computing the inferred outlives predicates for items in this crate
end of query stack
error: could not compile `deepwell`
Error: Process completed with exit code 101.

The relevant type is /deepwell/src/web/ratelimit.rs (declared as Arc<RateLimiter<IpAddr, DefaultKeyedStateStore<IpAddr>, DefaultClock>>), which sources its internals from the governor crate.

This happens intermittently, I cannot reproduce it consistently. If there's any other information I will do my best.

@Serial-ATA
Copy link
Contributor

rust-lang/rust#92163

@giraffate giraffate added the I-ICE Issue: Clippy panicked, giving an Internal Compilation Error (ICE) ❄️ label Dec 27, 2021
@heisen-li
Copy link

You can delete the incremental cache, or use CARGO_INCREMENTAL=0 environment variable to disable it.

@flip1995
Copy link
Member

Closing in favor of rust-lang/rust#92163 (nothing that could be done in Clippy)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I-ICE Issue: Clippy panicked, giving an Internal Compilation Error (ICE) ❄️
Projects
None yet
Development

No branches or pull requests

5 participants