From 2a0ef12b7013b94a80eeb8aa826a13934d5ff0aa Mon Sep 17 00:00:00 2001 From: ScriptedAlchemy Date: Sat, 19 Sep 2026 21:38:25 +0000 Subject: [PATCH] test(code-index): fence the busy follow-up expired-proof read The test held the admission permit and the owner pass guard while it aged the source proof, but the graph tail renews the proof after both read idle, so the read could observe a fresh proof and the abstain assertion failed. Hold the scheduler mutex across the aging and the read, the fence #1867 introduced for the same window. Co-Authored-By: Claude Fable 5.1 --- .../src/code_index_scheduler/tests/reconcile.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/tracedecay-code-index-runtime/src/code_index_scheduler/tests/reconcile.rs b/crates/tracedecay-code-index-runtime/src/code_index_scheduler/tests/reconcile.rs index 0640752037..b5ce34ab39 100644 --- a/crates/tracedecay-code-index-runtime/src/code_index_scheduler/tests/reconcile.rs +++ b/crates/tracedecay-code-index-runtime/src/code_index_scheduler/tests/reconcile.rs @@ -2577,6 +2577,9 @@ async fn graph_read_during_reconcile_records_a_busy_follow_up() { .hold_reconcile_pass_for_test(fixture.path()) .await .expect("mounted worktree"); + // The permit and the pass guard leave the graph tail's renewals free to + // run (see `hold_scheduler_for_root`). + let scheduler = hold_scheduler_for_root(®istry, fixture.path()).await; let source_freshness = registry .source_freshness_for_root(fixture.path()) .await @@ -2598,6 +2601,7 @@ async fn graph_read_during_reconcile_records_a_busy_follow_up() { .is_none(), "an expired graph proof abstains while the owner pass is in flight" ); + scheduler.release().await; drop(owner_pass); drop(admission);