Skip to content

Empty a box in the turn its words go on the page - #787

Merged
max-sixty merged 2 commits into
mainfrom
ask-other-draft
Sep 18, 2026
Merged

max-sixty merged 2 commits into
mainfrom
ask-other-draft

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

Adding an option to an Ask left the reader's words on screen twice: once as the option the press had just drawn, and once still sitting in the add field, until the log answered and cleared it. (There is only one add form — the new option is inserted above it, so the form looks like a second box that appeared below.)

The two senders in the draft store were split on whether the log alone could supply the gesture's result. That distinction had stopped being true: every dispatch paints its projected outcome synchronously before returning the delivery promise, so both senders draw their result before they are answered. lf-draft covered for it by closing its editor first, because the open editor also defers projection; the add field had nothing covering for it. It also broke the rule in skills/leaf/assets/CLAUDE.md that where the page can produce the result itself, it produces it in the gesture — the page produced it and left the before-state beside it.

So the mask sendMessage kept for itself moves into standGesture, which both senders now stage through: the generation is masked in this document at the gesture, the record stands in the store until the log settles it, and a refusal withdraws the result and gives the words back.

That also stops a pick made mid-send from stranding the option it was sending. Each pick rewrites the add field's draft, because the choice that draft would submit has changed, so one made while the send was open minted a new attempt over the generation that send owned; its answer then settled nothing and the words stayed in the box for good.

Two tests in tests/test_render_options_addition.py cover the hand-over and the mid-send pick, and both fail against the reverted fix. Alongside the suite I drove the three delivery outcomes in a real browser on a throttled POST: acceptance, a final 400 (option withdrawn, words returned), and a transient failure the outbox retries (mask holds, then settles).

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

max-sixty and others added 2 commits September 18, 2026 00:02
Adding an option left the reader's words on screen twice: once as the option
the press had just drawn, and once still sitting in the add field, until the
log answered and cleared it. The two senders in the draft store were split on
whether the log alone could supply the gesture's result, and that distinction
had stopped being true — every dispatch paints its projected outcome before its
delivery resolves, so both senders draw their result before they are answered.
`lf-draft` covered for it by closing its editor first; the add field had nothing
covering for it.

So the mask `sendMessage` kept for itself moves into `standGesture`, which both
senders now stage through: the generation is masked in this document at the
gesture, the record stands in the store until the log settles it, and a refusal
withdraws the result and gives the words back.

That also stops a pick made mid-send from stranding the option it was sending.
Each pick rewrites the add field's draft, so one made while the send was open
minted a new attempt over the generation that send owned; its answer then
settled nothing and the words stayed in the box for good.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@max-sixty
max-sixty merged commit e5394c6 into main Sep 18, 2026
5 checks passed
@max-sixty
max-sixty deleted the ask-other-draft branch September 18, 2026 07:45
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