You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
Fixed
A task PR could change the fence and the lead config. Section 8 of docs/design/edit-fence.md says that a fence mode change is a lead decision in a config PR, but nothing enforced it: a worker could commit "fence": "off" (or new claude_flags, providers, a merge_cmd, a settings hook) and the merge put it on the default branch. Now gate-check and the refinery refuse a task PR (a PR with Task:, Attempt: and Lease: lines) that changes fence, merge_cmd, check_cmd, protected_paths_cmd, providers or hosts[].claude_flags/env in .claude/wavecoord.json, the keys hooks, disableAllHooks, enabledPlugins, extraKnownMarketplaces or env in .claude/settings.json or .claude/settings.local.json, or any hooks/hooks.json. The violation kind is config_change, and the refinery reason is config_change, with a detail that tells the lead to make a plan or config PR. It blocks in the merge modes advisory and enforce (advisory mode measures the path fence; it does not let a worker turn the fence off), and is only reported in mode off. The mode comes from the config on the base side. Plan PRs and lead PRs have no such lines and are not affected. New seeded defect D24 with the table check config_change_check, and a refinery test.
Fence simulation flake: "journal not sent after a reachable call" under load. Seed 631187689 failed on Python 3.9 under heavy parallel load. The fence was right: the check answered but used the whole hook budget (1.5 s in the tests), so the journal flush had no time left, and the journal stayed complete for the next reachable call. The design allows this (section 4.4: only an acknowledged entry leaves the journal, and E3 refuses while it is not empty). The flush does not get its own budget slice, because that would make the edit tool call wait longer than the E1 budget. Assertion 5 now accepts a journal that stays only when the hook run's client got no answer, a request of the flush got no answer, or the budget ended before the flush (fencesim.flush_deferred). A flush whose requests all got answers must still empty the journal, and the end of each run still needs one reachable call to send all of it. The hook now flushes the journal before the spool replay, because only the journal stops a push. New deterministic tests: a slow check that uses the budget (the journal stays whole, E3 refuses, the next call sends it), and a check that the tolerance does not cover a flush that kept acknowledged entries.
Added
A report for a run that ran out of turns. Workers on non-Anthropic models through Anthropic-compatible endpoints (for example GLM) used about 1.5 to 2 times the planned turns and hit error_max_turns before they wrote the report, so the lead got "report invalid". Now, when the result is error_max_turns or the run hit its token budget, and the launcher pushed commits, the launcher writes a valid failed report with the commits, the changed files, checks_run empty and plan_feedback: "continue: <n> commits pushed", and sets continue_suggested: true on the report request, the result and the attempt.
Planning guidance for turn budgets.wave-plan (exec-plan.md, llm-risks.md): non-Anthropic providers need about 2 times max_turns, and the prompt should tell the worker to batch shell commands and not to read a file again. /wavecoord:triage: on continue_suggested, continue the same attempt with wavecoord launch --continue and a short prompt that lists the acceptance commands. The worker rules (the appended system prompt) now say: when fewer than 15% of the turns remain, stop, commit and write the report.