bash startup deadline: don't name a call as its own blocker; rebind wait diagnostics

Merged
AF
1d ago
+278-13

Diagnostics for the intermittent Windows failure of subc::tests::rebind_never_leaves_a_root_initializing_indefinitely, plus one diagnostic bug.

Diagnostic bug. A bash call takes its root's Mutating lane before its startup callback reports entry. So when its startup deadline expired, bash_start_deadline could say it was "queued behind root Mutating job ", naming itself as the blocker. Each attempt is now told apart by its cancellation token, since request IDs can repeat.

  • Own job: the reply prints the existing generic sentence "bash startup deadline: queued for executor admission or scheduler lock; …".
  • Another job holds the lane: the printed text is unchanged.
  • Both cases add detail.{job_id, age_ms, execution_started, own_job} and one warn log line. No new printed wording.

Rebind test diagnostics. On failure, including panics inside the helper, the test prints the database-open slot state (without waiting on it), unfinished opens, the root's scheduler jobs with lane and age, bind barriers and dispatcher pressure.

The stall itself is still unexplained: 40 of 40 native Windows runs passed, alone and with neighbours. These diagnostics are meant to name the blocker if it happens again.

Build server (current main): 242 subc bash, rebind and executor tests, formatting and the Windows check.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.


Summary by cubic

Fixes bash startup deadline diagnostics so a call no longer names itself as its own blocker, and adds failure diagnostics to the intermittent Windows rebind test stall.

Bash admission diagnostics

  • Distinguishes the current call from other scheduler occupants by cancellation token instead of request ID, which can repeat across calls.
  • When the deadline expires with the call itself holding the Mutating lane, the reply keeps the generic "queued for executor admission or scheduler lock" wording; another job holding the lane keeps the existing "queued behind root Mutating job" wording.
  • Both refusal paths now include detail.{job_id, age_ms, execution_started, own_job} and one warn log line; no printed wording changed.

Rebind test diagnostics

  • On test failure, including panics inside helpers, prints database-open slot state without waiting on locks, unfinished opens, root scheduler jobs with lane and age, bind barriers, and dispatcher pressure.
  • The stall remains unexplained; these diagnostics are intended to name the blocker if it recurs.