Skip to content

Keep fabricated setup turns inside the shared model window - #96

Merged
easel merged 1 commit into
mainfrom
claude/fixture-model-window
Nov 9, 2026
Merged

easel merged 1 commit into
mainfrom
claude/fixture-model-window

Conversation

@easel

@easel easel commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Summary

test_binding_provider_mutation_cannot_rewrite_final_policy_actor[jsonl] failed once during fixture setup. The shared client harness fixture's fabricated turn ended model_unavailable instead of confirmation_required.

The cause is the shared limits fixture, which gave each model request 5 seconds. That window also covers the attempt recorder's journal commits, made when the scripted model reserves, starts and observes its attempt. On JSONL, each of those commits syncs to disk. About 8 or 9 syncs fall inside the window, so on a loaded host (load average around 30 at the time) they can use all 5 seconds.

This PR raises the shared ceiling to 15 seconds and adds a comment explaining why. Commit 8a39da8 made the same change for the native restart case.

Evidence

  • With each fsync slowed to 0.5 s, the old window fails with reason=timeout and the new window passes. At 0.3 s, both pass.
  • Every test that checks a model timeout sets its own per-request window of 0.01 s to 1 s, so no timeout assertion is weakened or slowed.
  • make check passes locally on macOS arm64: 87% branch coverage, with lint, typing and the architecture checks clean.

Not changed

  • The 30-second JSONL lease is unchanged. With a sustained 0.6 s per sync, the fixture's unrenewed store.turn lease expires instead. The lease is a real protocol bound, and real stalls come in bursts rather than as a steady delay.
  • The product code is unchanged. A stalled journal still reports as a model timeout; whether to label it differently is a separate design question.

🤖 Generated with Claude Code

The shared test limits gave each model request 5 seconds. That window also
covers the attempt recorder's journal commits, and on JSONL each commit syncs
to disk. On a loaded host those syncs can use the whole window, so the client
harness's fabricated setup turn ended model_unavailable (reason timeout)
instead of confirmation_required. Slowing each sync to 0.5 s reproduces it;
the 15-second window passes. Timeout tests set their own short per-request
windows, so none is weakened or slowed.

Co-authored-by: Erik LaBianca <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
@easel
easel merged commit 94922c8 into main Nov 9, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant