Skip to content

Drop what the delivery and workflow cutover left stale, and check the site's sample delivery - #988

Merged
max-sixty merged 2 commits into
mainfrom
nightly/cutover-leftovers
Sep 23, 2026
Merged

max-sixty merged 2 commits into
mainfrom
nightly/cutover-leftovers

Conversation

@leaf-agent

@leaf-agent leaf-agent commented Sep 23, 2026 •

Copy link
Copy Markdown
Collaborator

Yesterday's delivery and workflow changes (#933, #939, #943) left readers and descriptions of shapes that no longer exist. The worst case was the published sample on https://leaf.page/how-it-works/. Its batch lists "conversations": [] beside a comment that opens conversation ebe8f367, but since #939 every conversation a batch names travels with its metadata. That sample is hand-copied and nothing checked it. This PR corrects the sample and adds test_how_it_works_delivery_has_the_shape_a_real_delivery_has, which freezes a real delivery and requires the sample to name the same batch keys, the same conversation-entry keys, and every conversation its events name. On the old sample it fails with assert [] == ['ebe8f367'].

It stops there: the sample's event entries and its five handling paragraphs are still unpinned, so the clause text the page publishes as agent guidance can still drift from what event_clauses produces. Both are reachable from the same frozen delivery this test now builds — the clause texts are already byte-identical to h4 and h5 — and pinning the event keys wants a comment appended through the path that stamps revision, which this test's append_event does not.

The rest removes code nothing reaches any more, and corrects or de-duplicates text that outlived what it described:

  • open_session_turn(delivered=...): its only caller that passed a transaction went away with the old watch pass. receive_delivery now opens each delivered page's turn itself. The parameter, both branches, and the docstring paragraph describing them are gone.
  • activity.py: drops item.pop("anchor", None). Only the removed acknowledgments.py receipts carried anchor.
  • scripts/verify-site-browser.js / verify_site.py: the undrawn-reply diagnostic printed stream= from data-stream-state. Unify message workflow and derive thread attention #933 removed that attribute's only writer, so every failure printed stream=None.
  • worker/test/index.test.ts: the specimen-route test mocked obligations: [{ event }], the pre-rename shape. Its "no agent work" assertion held whatever the routing did. The test now uses input like the other cases.
  • Stale descriptions: the canonical_workflows docstring now says a failed response keeps a reader-facing workflow. The Watch docstring no longer lists pickup recording, which moved to receipt. leaf wait's short help no longer says it prints one page's events and exits. Its snapshot is regenerated.
  • worker/README.md: the Observability section restated that the Tend CI token holds no tail permission. That is still true — the token is current and the table above still describes it — but the same section already says Workers Metadata Read-Only is what lets a token tail, and only the agent administration token holds it. The restatement goes; the capability stays stated once.

lint and test are green on d88d53f. Locally, the worker's typecheck and npm test pass, and the touched Python suites pass except cases the bot sandbox cannot run (Unix sockets, Chromium, file modes).

… site's sample delivery

The how-it-works sample batch listed no conversations beside a comment that
opens one; a new product-page test now holds its keys and conversation list to
a delivery frozen from a real page. Also removes open_session_turn's unused
delivered parameter, activity's dead anchor pop, the verifier's stream field
whose writer #933 removed, and the worker specimen test's pre-rename obligation
shape, and corrects the docstrings, wait help and worker README lines that
described removed behavior.
@max-sixty
max-sixty merged commit 17e45a3 into main Sep 23, 2026
4 checks passed
@max-sixty
max-sixty deleted the nightly/cutover-leftovers branch September 23, 2026 14:26
max-sixty added a commit that referenced this pull request Sep 23, 2026
#1005 restored delivery receipts for page actions that answer no Ask,
while keeping their `answer` null so they do not create agent
obligations. That changes the contract against which #1004 updated three
nightly cases.

Restore the original export, Page Map arrival, and shipped-board
margin-rail tests. They again cover a draft edit and ordinary card moves
with real Sent / Picked up / Working readings. Keep #1004's
single-choice fixture in the margin-label test: a tick in a
multiple-choice Ask still produces no receipt before Done.

Verification on the PR's base at `0cccbdc`: all three restored cases
plus the retained margin-label case pass together under `--run-nightly
-n0` (4/4). Pre-commit passes on the changed files. The later #988 merge
changes only the workflow docstring in the code these cases exercise.

> _This was written by Codex on behalf of max-sixty_
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.

2 participants