Problem
AppServerClientTests.backendAdmissionRefusesThreadStartBeforeDispatch creates the cancellation task and immediately opens the held initialize response. It does not wait for ReviewStartAdmission to record the cancellation owner.
If initialization resumes first, the backend legitimately reaches thread/start; the fake has no queued thread response and decodes {} as Thread.Start.Response, producing the intermittent keyNotFound("thread") failure seen in full package runs. The test passes individually when cancellation happens to win.
Required fix
After creating the cancellation task, wait for the semantic cancellation admission (.mcpClient("Stop")) before opening the initialize gate. Keep production unchanged. Search the neighboring AppServer admission fixtures for the same task-scheduling assumption.
Acceptance
- Deterministically proves zero
thread/start writes after admitted pre-dispatch cancellation.
- Repeated focused runs and the full AppServer/full package suites pass.
- No sleeps,
Task.yield(), request-count ordering, or production changes.
Problem
AppServerClientTests.backendAdmissionRefusesThreadStartBeforeDispatchcreates the cancellation task and immediately opens the heldinitializeresponse. It does not wait forReviewStartAdmissionto record the cancellation owner.If initialization resumes first, the backend legitimately reaches
thread/start; the fake has no queued thread response and decodes{}asThread.Start.Response, producing the intermittentkeyNotFound("thread")failure seen in full package runs. The test passes individually when cancellation happens to win.Required fix
After creating the cancellation task, wait for the semantic cancellation admission (
.mcpClient("Stop")) before opening the initialize gate. Keep production unchanged. Search the neighboring AppServer admission fixtures for the same task-scheduling assumption.Acceptance
thread/startwrites after admitted pre-dispatch cancellation.Task.yield(), request-count ordering, or production changes.