Repository navigation
Hold idle and the Stop hook to one set of owed moves, and read the layer's registry once - #1221
Merged
Merged
Conversation
`leaf status idle` and the Stop hook each decided which acknowledged user moves still block the agent, and only the hook knew the two moves another turn answers: one a Codex carrier queued for a later turn (#459), and a `turn` answer the open turn has finished, which a live carrier commits once the turn ends (#1080). So a turn that queued a batch could end but was refused `leaf status idle` over the same move. `activity.blocking_obligations(state, carried=)` is now the one rule, read by both; `session-lifetime.md` states it once. The prompt hook opens `activity.acknowledged_obligations`, the queued ones included, as before. The recorded `$layer.packages` a bare `leaf page init` re-vendors with is read through `registry.storage.layer_packages`, which `layer_metadata` also uses, rather than a copy of that rule with its own message. It reads only the packages, so a page whose other `$layer` fields are broken can still be re-vendored, which is the remedy `layer_metadata`'s errors name. `session._page_stamp` is renamed `_page_reading_or_none`: it wraps `page_reading`, and `presence._page_stamp` is a different stamp. Behaviour that moved: - `leaf status idle` accepts a page whose only owed move is queued for a later turn, and (with a live carrier) one whose turn answer the open turn has finished (`test_idle_and_the_stop_hook_hold_the_agent_to_the_same_moves`). - A malformed `$layer.packages` on re-init reports the registry reader's message. - `test_a_completed_stream_answers_its_event_even_when_the_reply_address_differs` asserts through `blocking_obligations`, including the dead-carrier case. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
previously approved these changes
Sep 26, 2026
`page init` checked a re-vendor against the incoming layer with its own composition of the page's declarations and widgets, beside `registry.storage.read_page_registry`'s. Both now call `registry.storage.compose_candidate(page_dir, layer, widgets)`, and `widget_paths` lists a directory's widget modules for both. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
reviewed
Sep 26, 2026
leaf-agent
left a comment
Collaborator
There was a problem hiding this comment.
A bare re-vendor now refuses a broken registry entry that the re-vendor would replace.
`layer_packages` read registry.json through `read_registry_declarations`, which refuses a malformed entry, so a bare `leaf page init` could not replace the broken vendored registry it exists to repair. It now reads the file as JSON and applies only the packages rule. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
approved these changes
Sep 26, 2026
max-sixty
added a commit
that referenced
this pull request
Sep 27, 2026
The concept survey's drifted duplicates now each have one owner (#1214–#1221, #1223, #1228, #1231, #1235, #1244, #1245, #1247, #1250, #1251, #1254, #1260), so the survey note never lands. What it found and nobody has taken becomes `TODO.md` entries: - **Shared definitions** (new section under Next): re-addressing resource references in one pass instead of `http.py`'s regex scopers and three head composers; `tests/render_harness.py` `told()` beside `pageReadiness`'s `data` and `log` stages (#1250), which answer the same question; Python still naming a thread's identity a root (`thread_roots`, `FrozenThreadReading.roots`) now that the runtime keys threads on the served `id` (#1260). - **Requests**: the existing "Decide whether requests earn their weight" entry now says kept requests need one owner for seat availability, which four runtime modules restate. - **Implementation candidates**: the unresolved-gesture ledger as one state machine, deferred until a change has to touch it, since nothing there has drifted and it is the hottest race path. The survey's small undrifted items and its list of deliberate splits are dropped: none has drifted, and the splits are intended. 🤖 Generated with [Claude Code](https://claude.com/claude-code) > _This was written by Claude Code on behalf of max-sixty_ --------- Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
leaf status idleand the Stop hook each decided which acknowledged usermoves still block the agent, and only the hook knew the two moves another
turn answers: one a Codex carrier queued for a later turn (#459), and a
turnanswer the open turn has finished, which a live carrier commits oncethe turn ends (#1080). So a turn that queued a batch could end but was
refused
leaf status idleover the same move.activity.blocking_obligations(state, carried=)is now the one rule, readby both;
session-lifetime.mdstates it once. The prompt hook opensactivity.acknowledged_obligations, the queued ones included, as before.Two registry readings
vendoring.pyrestated now come fromregistry/storage.py:$layer.packagesa bareleaf page initre-vendors with isread through
layer_packages, whose checklayer_metadatashares, ratherthan a copy of that rule with its own message. It reads the file as JSON
and checks only the packages, so a page whose other
$layerfields orregistry entries are broken can still be re-vendored, which is the remedy
layer_metadata's errors name(
test_a_bare_re_vendor_replaces_a_broken_vendored_registry).page initchecks a re-vendor against iscomposed by
compose_candidate(page_dir, layer, widgets), the functionread_page_registrycomposes the vendored layer with, rather than asecond composition over the incoming layer.
session._page_stampis renamed_page_reading_or_none: it wrapspage_reading, andpresence._page_stampis a different stamp.Behaviour that moved:
leaf status idleaccepts a page whose only owed move is queued for alater turn, and (with a live carrier) one whose turn answer the open turn
has finished (
test_idle_and_the_stop_hook_hold_the_agent_to_the_same_moves).$layer.packageson re-init reports the registry reader'smessage.
test_a_completed_stream_answers_its_event_even_when_the_reply_address_differsasserts through
blocking_obligations, including the dead-carrier case.🤖 Generated with Claude Code