Repository navigation
test(daemon): drive tracedecay journey tests by signals, not wall bounds #4174
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
Changes from all commits
dbaaa05
d0ca91d
e8d63f9
c49608d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1176,24 +1176,13 @@ async fn daemon_admission_remains_ready_while_lcm_indexes_converge_in_background | |
| .expect("session runtime registry"); | ||
| let convergence_gate = registry.block_registered_schema_convergence_for_test(); | ||
|
|
||
| let admission = registry.project_sessions(project_id, [project_root]); | ||
| tokio::pin!(admission); | ||
| let convergence_blocked = convergence_gate.wait_until_blocked(); | ||
| tokio::pin!(convergence_blocked); | ||
| let database = tokio::time::timeout(std::time::Duration::from_secs(10), async { | ||
| tokio::select! { | ||
| result = &mut admission => { | ||
| let database = result.expect("registered project sessions"); | ||
| convergence_blocked.await; | ||
| database | ||
| } | ||
| () = &mut convergence_blocked => { | ||
| admission.await.expect("registered project sessions") | ||
| } | ||
| } | ||
| }) | ||
| .await | ||
| .expect("daemon admission and convergence scheduling must not stall"); | ||
| // The gate holds convergence until the assertions below, so an admission | ||
| // that waited on convergence never returns. | ||
| let database = registry | ||
| .project_sessions(project_id, [project_root]) | ||
| .await | ||
| .expect("registered project sessions"); | ||
| convergence_gate.wait_until_blocked().await; | ||
|
Comment on lines
+1181
to
+1185
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🟡 Admission regressions hang the test target If Learn moreThis journey checks that foreground admission does not wait for background schema convergence. The convergence worker waits inside block until this test calls Example: If admission starts awaiting convergence, convergence holds at the gate, and the test holds at Recommended fix: Retain a sufficiently measured finite admission guard that fails with a targeted diagnostic, while using the gate to assert that admission does not require convergence to finish. Was this helpful? React with 👍 or 👎 to provide feedback. |
||
|
|
||
| assert_eq!( | ||
| registry.registered_schema_convergence_status(&shard_id), | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟡 Permanent ingest refusals stall journey tests
If the refresh owner stays unavailable,
settled_server_session_ingestretries itsretryablerefusal without a bound. The session journeys run until Bazel kills the whole test target instead of reporting the failed ingest.Learn more
The session journeys use this helper to wait for a mounted project to finish ingesting. A missing or permanently failed refresh owner can return
temporal_refresh_unavailablewithretryable: trueon every call through join_hook_ingest_refresh. Removing the previous 30-second bound leaves no way for the helper to identify that failure locally; the Bazel test target issize = "large"and times out as a whole. The repository rules require tests to stay falsifiable and forbid weakening assertions or raising timeouts.Example: If the project's refresh owner remains unavailable, each ingest answers
temporal_refresh_unavailable; the helper sleeps 250 ms and repeats until Bazel terminates the suite, rather than failing this journey with its last refusal.Recommended fix: Keep a bounded, diagnostic failure path around the retry loop while allowing transient retryable refusals. Report the last typed problem when the bound is exhausted.
Was this helpful? React with 👍 or 👎 to provide feedback.