Skip to content

check --read-data can panic with "index still in use" #606

Closed

Description

@Akayashuu

check with read_data sometimes panics with index still in use when the machine is under load. We hit it on a busy CI runner with 0.13.0, and it reproduces on main.

thread '...' panicked at crates/core/src/index.rs:312:38:
index still in use

TreeStreamerOnce::new spawns the tree loaders with a clone of the index each and drops their JoinHandles (tree.rs). Once check_trees is done, check calls into_index() (check.rs), which only gives the loaders 100 ms to release their clones before the expect (index.rs). A loader that isn't scheduled in time triggers the panic.

To reproduce: an in-memory repo with ~120 directories, check with read_data in a loop, process pinned with taskset -c 0 next to 64 busy threads. 20 out of 20 runs panic on main.

Joining the loaders when the streamer is dropped fixes it, PR follows. #546 is related (loaders stop when the receiver is gone, but are still not joined).

Activity

  1. added
    S-triage
    on Oct 18, 2026
  2. added a commit that references this issue on Oct 30, 2026
    0db92b6
  3. added a commit that references this issue on Nov 5, 2026
    076d507
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    S-triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions