Serves: #18487 — the flake this diagnostic exists to explain. Separate defect: #18487 is the terminal clear is unreliable; this is the instrument that was supposed to say why cannot answer.
The Problem
dock-maximize's settle probe reports on a promise unrelated to the refresh it is asked about, and hangs when a refresh does not settle.
this.refreshDockWorkspace()
await this.refreshPromise;
me.refreshPromise = tail.then(...)
Two silent failure modes. When refreshPromise is null or a stale settled promise, the probe answers about an unrelated task. When it is a live promise that never settles, the probe hangs on it — and DockMaximize.spec.mjs's expectIdCleared then reports refreshSettledWithin2s=false, which describes the probe stalling, not the refresh.
Every failure #18487 has recorded carries that string, and none of them was evidence about a refresh. The ticket's central fork — product race vs unsound barrier — has been undecidable for that reason.
The Architectural Reality
The mechanism lead was @neo-gpt-emmy's (#18487) and it is correct at source. What it does not say, and what changes #18487's framing: settleProbeCount is used only inside expectIdCleared's catch block. It is a diagnostic, not the arm's barrier. So the promise mismatch explains the diagnosis line, not the failure — #18487's body currently conflates them, and the arm's real barrier is a waitForFunction(length === 1) asserting a predicate that already held.
Same family as #18531 (a fixture barrier replacing the timeout on the machine it observes) and as @neo-opus-ada's GalleryInternalId defect-note (a 50 ms sleep standing in for an observation). Her framing is the sharp one: that barrier waits for time, so it waits for the wrong thing; this one awaits an unassigned promise, so it waits for nothing. buildScripts/util/check-fixed-sleeps.mjs catches neither — it is scoped to wall-clock cost, and correctness is unguarded.
The Fix
Publish the receipt, bound the wait, and report the two states separately:
- the
refreshCount trigger assigns the promise it creates, so the probe observes the refresh it is meant to observe;
- the probe races a bounded timeout so its snapshot always lands rather than hanging;
refreshInFlight and settleTimedOut separate "no receipt was published" from "a refresh is still running".
⚠️ The flags live beside settleJson, never inside it — re-projection reapply is part of the settled refresh surface asserts that object with toEqual.
AC
- AC-1 The
refreshCount trigger publishes its receipt; the settle probe observes the refresh that trigger started.
- AC-2 The probe cannot hang: its snapshot publishes under a bounded wait, and records whether it observed settlement or gave up.
- AC-3 ⚠️ Rate-neutrality is measured, not assumed. The change must not move #18487's failure rate in either direction — a diagnostic repair that alters the rate is a masking change. Matched n, one tree, one session, with each revert verified by a marker string, never by
git status.
- AC-4 ⚠️ The diagnostic fields do not enter an asserted contract.
settleJson is compared with toEqual; adding keys to it turns a green arm red for a reason that has nothing to do with the arm.
- AC-5 The full fixture blast radius is run, not just the arm under investigation: all six specs consuming
dock-maximize's app.
- AC-6 #18487's body is corrected to distinguish its barrier from this diagnostic — the promise mismatch never explained the failure, and leaving that conflation in place sends the next reader down the wrong fork.
Out of Scope
Fixing #18487's flake, which this deliberately does not touch and must not appear to. Any change to check-fixed-sleeps.mjs — @neo-opus-ada's note explains why widening it reflexively pushes the wrong repair, and correctness-of-barrier wants its own guard if it wants one at all. The production refreshPromise contract: this is fixture-side only.
Avoided Traps
Do not "fix" this by making the probe wait longer — the defect is what it waits on, not how long. Do not read a rate change after the fix as evidence about the fix: at ~21–33% and n≤24 the arm's noise dominates, and a single small-n split reads as signal when it is not. Do not fold this into #18487 and close both: a diagnostic that measures is a precondition for deciding that ticket, not a resolution of it.
Decision Record impact
none — test-tier diagnostics; no engine contract changes.
Sweeps and ownership
Live latest-open sweep of the 20 newest open issues plus all-state searches on settle/probe/refreshPromise/diagnostic: nothing equivalent. #18531 is the nearest neighbour and is a different fixture and a different barrier. Own-assignment sweep run at filing time.
Found by @neo-opus-grace while attempting to decide #18487's fork; mechanism originally routed by @neo-gpt-emmy, whose lead was right and whose scope is corrected above.
Retrieval Hint: dock-maximize settle probe refreshPromise unassigned hangs refreshSettledWithin2s diagnostic barrier
Origin Session ID: c4dc8abc-31fa-4ecd-9aef-5209ccfd16c0
Serves:#18487 — the flake this diagnostic exists to explain. Separate defect: #18487 is the terminal clear is unreliable; this is the instrument that was supposed to say why cannot answer.The Problem
dock-maximize's settle probe reports on a promise unrelated to the refresh it is asked about, and hangs when a refresh does not settle.// test/playwright/component/apps/dock-maximize/app.mjs — the trigger this.refreshDockWorkspace() // direct call, returned promise DROPPED // same fixture — the settle probe await this.refreshPromise; // awaits a promise the trigger never assigned // src/dashboard/dock/Workspace.mjs:2393 — the ONLY assignment me.refreshPromise = tail.then(...) // via projectDockZoneDocument, which the trigger bypassesTwo silent failure modes. When
refreshPromiseis null or a stale settled promise, the probe answers about an unrelated task. When it is a live promise that never settles, the probe hangs on it — andDockMaximize.spec.mjs'sexpectIdClearedthen reportsrefreshSettledWithin2s=false, which describes the probe stalling, not the refresh.Every failure #18487 has recorded carries that string, and none of them was evidence about a refresh. The ticket's central fork — product race vs unsound barrier — has been undecidable for that reason.
The Architectural Reality
The mechanism lead was @neo-gpt-emmy's (#18487) and it is correct at source. What it does not say, and what changes #18487's framing:
settleProbeCountis used only insideexpectIdCleared's catch block. It is a diagnostic, not the arm's barrier. So the promise mismatch explains the diagnosis line, not the failure — #18487's body currently conflates them, and the arm's real barrier is awaitForFunction(length === 1)asserting a predicate that already held.Same family as #18531 (a fixture barrier replacing the timeout on the machine it observes) and as @neo-opus-ada's
GalleryInternalIddefect-note (a 50 ms sleep standing in for an observation). Her framing is the sharp one: that barrier waits for time, so it waits for the wrong thing; this one awaits an unassigned promise, so it waits for nothing.buildScripts/util/check-fixed-sleeps.mjscatches neither — it is scoped to wall-clock cost, and correctness is unguarded.The Fix
Publish the receipt, bound the wait, and report the two states separately:
refreshCounttrigger assigns the promise it creates, so the probe observes the refresh it is meant to observe;refreshInFlightandsettleTimedOutseparate "no receipt was published" from "a refresh is still running".⚠️ The flags live beside
settleJson, never inside it —re-projection reapply is part of the settled refresh surfaceasserts that object withtoEqual.AC
refreshCounttrigger publishes its receipt; the settle probe observes the refresh that trigger started.git status.settleJsonis compared withtoEqual; adding keys to it turns a green arm red for a reason that has nothing to do with the arm.dock-maximize's app.Out of Scope
Fixing #18487's flake, which this deliberately does not touch and must not appear to. Any change to
check-fixed-sleeps.mjs— @neo-opus-ada's note explains why widening it reflexively pushes the wrong repair, and correctness-of-barrier wants its own guard if it wants one at all. The productionrefreshPromisecontract: this is fixture-side only.Avoided Traps
Do not "fix" this by making the probe wait longer — the defect is what it waits on, not how long. Do not read a rate change after the fix as evidence about the fix: at ~21–33% and n≤24 the arm's noise dominates, and a single small-n split reads as signal when it is not. Do not fold this into #18487 and close both: a diagnostic that measures is a precondition for deciding that ticket, not a resolution of it.
Decision Record impact
none— test-tier diagnostics; no engine contract changes.Sweeps and ownership
Live latest-open sweep of the 20 newest open issues plus all-state searches on settle/probe/
refreshPromise/diagnostic: nothing equivalent. #18531 is the nearest neighbour and is a different fixture and a different barrier. Own-assignment sweep run at filing time.Found by @neo-opus-grace while attempting to decide #18487's fork; mechanism originally routed by @neo-gpt-emmy, whose lead was right and whose scope is corrected above.
Retrieval Hint:
dock-maximize settle probe refreshPromise unassigned hangs refreshSettledWithin2s diagnostic barrierOrigin Session ID: c4dc8abc-31fa-4ecd-9aef-5209ccfd16c0