fix(index): work around rustc nightly ICE in NGramIndexBuilder::stream_spill_reader#7534
Merged
westonpace merged 2 commits intoJun 30, 2026
Merged
Conversation
…m_spill_reader The function was declared `async` but never awaited anything at the top level — `num_rows()` is synchronous and the unfold stream is built synchronously. The unnecessary `async` triggered an internal compiler error in recent nightly builds: error: internal compiler error: Obligation DynCompatible(IndexReader) should have been handled by fulfillment already. (#0 evaluating async fn body of stream_spill_reader as Future) Removing `async` and dropping the corresponding `.await` at call sites avoids the ICE while preserving identical runtime behaviour. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Two more async fns returning impl Stream triggered the same ICE as stream_spill_reader (DynCompatible obligation reaching trait selection before fulfillment): - FilteredReadStream::read_fragment: already boxes its return value internally; change the declared return type from impl Stream to BoxStream to avoid the opaque type that triggers the ICE. - FragmentScanner::scan: no top-level awaits; remove async and drop the corresponding .await at the call site. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
xuanyu-z
approved these changes
Jun 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The function was declared
asyncbut never awaited anything at the top level —num_rows()is synchronous and the unfold stream is built synchronously. The unnecessaryasynctriggered an internal compiler error in recent nightly builds:error: internal compiler error: Obligation DynCompatible(IndexReader)
should have been handled by fulfillment already.
(#0 evaluating async fn body of stream_spill_reader as Future)
Removing
asyncand dropping the corresponding.awaitat call sites avoids the ICE while preserving identical runtime behaviour.