-
Notifications
You must be signed in to change notification settings - Fork 13.3k
rustc panicked: "Failed to extract DefId" #125945
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
Comments
no repro building this locally and a what was the last change you made just before this? |
I added this for loop for map_table in html.select(&self.table_selector) {
println!("TABLE: {map_table:?}");
} Indeed, I then tried to remove lines to track down the error and eventually got to compile this exact file, so it probably was some incremental compilation issue. |
Did you rename anything by any chance? Specifically enum variant name, enum or struct field name, or struct name? |
I seem to be able to reproduce consistently, but sadly on a rather large project. I'm posting how to repro in case it can help anyway. Same exact rustc version. git clone https://github.com/quickwit-oss/quickwit
cd quickwit/quickwit/quickwit-indexing
git checkout 1c2ec26662ae7d5e8cc041bd31fabef34d08fa33
cargo check
git checkout 05559785be0a132d89ee569b0eff27fa7fb0c084
cargo check # <= fails here full delta: quickwit-oss/quickwit@0555978 diff extract of where struct fields are changed (both name and type): pub struct DocProcessorCounters {
index_id: IndexId,
source_id: SourceId,
+
/// Overall number of documents received, partitioned
- /// into 4 categories:
+ /// into 5 categories:
+ /// - valid documents
/// - number of docs that could not be parsed.
+ /// - number of docs that were not valid json.
/// - number of docs that could not be transformed.
/// - number of docs for which the doc mapper returnd an error.
/// - number of valid docs.
- pub num_doc_parse_errors: AtomicU64,
- pub num_transform_errors: AtomicU64,
- pub num_oltp_parse_errors: AtomicU64,
- pub num_valid_docs: AtomicU64,
+ pub valid: DocProcessorCounter,
+ pub doc_mapper_errors: DocProcessorCounter,
+ pub transform_errors: DocProcessorCounter,
+ pub json_parse_errors: DocProcessorCounter,
+ pub otlp_parse_errors: DocProcessorCounter,
/// Number of bytes that went through the indexer editalso fails with rust 1.79, though the error seems slightly different
Error output:
backtrace
|
Reliable reproduction is more important, example can always be reduced. Fixed by #126409 |
i can no longer reproduce with
|
It seems likely that #126409 fixed it then |
Thank you for reporting the no-repro! |
I was trying to write a webscraper and somehow got this error. I'm not sure what caused it, but I only have one
main.rs
file so it should be relatively a small surface area. This is myCargo.toml
:Code
Meta
rustc --version --verbose
:Error output
Backtrace
The text was updated successfully, but these errors were encountered: