Skip to content

Record product decisions in module headers, and accept a red main for now - #1780

Merged
max-sixty merged 10 commits into
mainfrom
arrival-opens-held-replies
Oct 5, 2026
Merged

max-sixty merged 10 commits into
mainfrom
arrival-opens-held-replies

Conversation

@max-sixty

@max-sixty max-sixty commented Oct 5, 2026 •

Copy link
Copy Markdown
Owner

Records decisions from the held-news case study where the next change will read them.

The branch also carries that focus-derived arrival attempt and its revert, for reference; the net diff is the three records above.

This was written by Claude Code on behalf of max-sixty

max-sixty and others added 5 commits October 4, 2026 16:58
Held news showed on arrival only where a route remembered to call
`showHeld`: the t/T walk's panel path, `openPageThread`, the panel's
`showThread`, `materializeAsk`, and the panel list's title choice (#1705).
A `carried` flag, threaded through three signatures, kept a reply box being
put back from releasing anything. Each new route to a thread was one more
place to forget, and each fix since #1694 found one.

Arrival is now a fact held-news.js derives once, from focus. Focus that
lands in a thread other than the one the user stands in arrives there,
whatever route moved it. Focus the runtime puts back or a chrome placement
hands across (`restoringFocus`, `placingChrome`) moves the standing without
arriving. A press inside a thread stands the user where it lands, so it
releases nothing: drawing the news would move what is under the press. A
press on a card's title asks for the thread, so it arrives. The release is
synchronous and runs ahead of any landing listener, so a landing measures
the thread with its news in it.

All five `showHeld` call sites and the `carried` flag are gone. `showHeld`
remains for the one case focus can't cover: a destination that is itself
held, a message or an Ask in a held turn, has no node to focus until it
shows. The panel list's `gesturedOn` and held-news's `ownTurn` read the
same ledger, and they are now one reading, `ownGestures`.

Behavior that moved:
- Pressing t/T at the end of the list, onto the thread the user already
  stands in, no longer releases its news. Focus doesn't move, so it is a
  stay. `test_walking_to_a_thread_shows_the_replies_it_held[*-onto]` now
  asserts the notice stays. A new `return` case covers walking back onto a
  card that stood open throughout, from outside it.
- Going to an Ask from inside the same thread is also a stay. The
  `standing-ask` case now starts outside the thread.
- The held diff-thread reply test now presses into the reply box rather
  than focusing it from script. A press into the box keeps the reply held,
  which the test now asserts.

Disabling the arrival release fails `return`, `standing-ask` and the
page-seat `walked` case.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Part of the focus-derived arrival attempt; see the following revert.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…for now

Two decisions from the held-news case study, so later agents read them
rather than relitigate them.

`AGENTS.md`, "Where instructions live": a product decision a module
embodies is part of its contract, so its header names the alternatives
the decision rejected and why. A change that reverses one rewrites that
record and says so in its commit. #1525 kept its rejected alternative in
`TODO.md`, and #1694 deleted it and adopted that alternative without
mentioning the reversal.

`tests/AGENTS.md`: the narrow pull-request gate is a deliberate trade. A
pull request can land green and break a nightly test it never ran, and
main's complete suite can stay red while `tend-ci-fix` repairs it. Keeping
main green is not a goal for now, so a red main is not by itself a reason
to widen a change, its gate, or its test selection.

The branch also carries a focus-derived arrival signal for held news and
its revert. Review found that it misses focus moves inside one shadow tree,
counts a dialog's hand-back as an arrival, and lets a press drift from
focus. It is kept for reference only; the net diff is these two notes.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
leaf-agent previously approved these changes Oct 5, 2026
max-sixty and others added 2 commits October 4, 2026 22:35
…ecords before changing a module

held-news.js's header now records that a panel card holds news behind its
notice (#1694), the choice #1525 recorded and the alternatives it rejected,
and that arrival stays a set of call sites because deriving it from focus
events missed shadow-tree moves and dialog hand-backs. /developing-leaf
tells a change to read a module's decision record first, write a decision
it settles there, and ask the user before reversing one they made.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@max-sixty max-sixty changed the title Record where product decisions live, and that a red main is accepted for now Record product decisions in module headers, and accept a red main for now Oct 5, 2026
…ull-request gate

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
leaf-agent previously approved these changes Oct 5, 2026
AGENTS.md, "Where instructions live", already states the rule; a second copy
near the top of the skill gave it more weight than it carries.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@max-sixty
max-sixty merged commit b222170 into main Oct 5, 2026
4 checks passed
@max-sixty
max-sixty deleted the arrival-opens-held-replies branch October 5, 2026 06:05
max-sixty added a commit that referenced this pull request Oct 6, 2026
Held thread news showed on arrival only where a route remembered to call
`showHeld`, and routes that put the user back opted out with a `carried`
flag or a `restoringFocus()` check. This reads arrival once, from where
the user stands.

- `runtime/focus.js` publishes each change to where the user stands
(`onStanding`), labeled `return` (a hold restoring, a chrome placement,
`returningFocus`, `handBack`, or the platform returning focus from a
layer it closed), `press` (focus landing where the last press was), or
`move` (a key's own move or a route). Each shadow stage reads its own
`focusin` (`watchStandingIn`, called from `shadowStage`), since a move
inside one shadow tree reaches the document as no event.
- `thread/held-news.js` subscribes: coming to stand in a thread from
outside it, by a `move` or a `press` on its title, shows what any seat
holds of it. Coming back to the thread the user stood in, and any move
within it, is a stay. The release runs inside the `focus()` call, before
each route measures its landing.
- The five `showHeld` call sites, `carried`, and the title choice's
check are gone. `showHeld` stays only where the destination is itself
held (a message or an Ask in a held turn); `showHeldThread` shows a
thread a seat holds whole where no surface draws it, so a walk to it
lands in its outlet.
- The More menu's hand-back of borrowed focus goes through
`returningFocus`.

This reverses the record #1780 wrote in `held-news.js` (arrival as the
routes that call `showHeld`), at the user's decision on the held-news
case-study page; the header now records the rejected alternative.

Behavior that moved: t/T onto the thread the user already stands in,
going to an Ask from inside its thread, and Escape out of a panel card's
reply box onto its title are stays, so held news stays behind its
notice; a press into a thread's reply box keeps what it holds. The
commit message lists each with its test.

Tests: the earlier attempt's two gaps each have a test that fails
without the fix (an in-stage return in the diff-thread read test,
without `watchStandingIn`;
`test_a_dialog_handing_the_user_back_to_a_thread_is_no_arrival`, without
the closed-layer return), as does the outlet walk
(`test_a_walk_to_a_thread_a_diff_line_holds_lands_in_its_outlet`).
Locally `test_render_threads.py`, `test_render_read_state.py`,
`test_render_drafts.py` and `test_render_reactions.py` pass (491), as do
`npm run test:runtime` and pre-commit; a wider run over navigation,
margin, widgets and aim showed only load flakes and two aim failures
that fail the same way on main.

> _This was written by Claude Code on behalf of max-sixty_

---------

Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
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