Repository navigation
Let replies distinguish follow-up from reader questions - #74
Conversation
leaf-agent
left a comment
There was a problem hiding this comment.
The distinction itself reads well, and keeping the structured case on the x-awaits projection rather than a second event flag is the right call — the CLI's refusal of --awaits beside ask markup is what makes that one authority rather than two.
Three things on how the browser side pays for it, inline. The first is a real leak rather than a style point: renderThreads now builds a full thread node — reply box included — for every open thread, and a thread the narrowing hides has no node to reuse, so it is rebuilt on every reconcile and each rebuild registers document listeners that are only pruned lazily.
One thing outside the diff, for later rather than for this PR: awaitsReader still treats an agent comment as asking regardless of what its markup declares, so a reader who answers an x-awaits widget in an agent comment empties the banner's ask count while the panel keeps that thread in "Waiting on you" — the same divergence this PR closes for replies. openAsks counts a widget an agent sent as an ask like any other, so both surfaces already see the widget; only the thread fold ignores it.
The render gate used to reach /api/state behind a networkidle navigation, which waited out the page's first poll and the append that rode on it. The news stream leaves the network never idle, so the gate now navigates on load and can reach /api/state while the page's first read is still in flight — whereupon it counts an empty log, waits for nothing, and reads a page 120px mid-move. That is what CI reported at run 33053132232. The window this test constructs is now stated on both sides: the action still goes in behind the page's first read, and the gate's own read is held until it has. A 0.4s delay on the page's read reproduces the CI failure exactly on the old test and passes on the new one at 2s, so the ordering is an arrangement rather than a margin. The premise assertion moves ahead of the gate's verdict, since a window that never opened makes that verdict say nothing.
leaf-agent
left a comment
There was a problem hiding this comment.
The staging rewrite reads well — projecting msgBody(last) under skeletal ancestry keeps the reply box out of the reconcile entirely, and batching the reducer over one askContext() closes the quadratic fold. Dropping the thread parameter leaves inChrome as the single term, which is what the connection contract was already carrying.
One thing on the regression test, inline. The listener counters and the lf-options connectedCallback probe both earn their init script — neither fact survives to the Playwright boundary — but the gesture that drives the reconcile does not need to be synthetic. findInput's handler is a plain input listener, so renarrow() runs either way; what the dispatch loses is that a reader cannot produce three input events with findInput.value unchanged. tests/CLAUDE.md under Drive the browser a reader gets asks for page.keyboard where the gesture matters, and this repo's running-tend names a gesture swapped to dispatchEvent as one of the shortcuts that greens a run while weakening what it proves. Real keystrokes give the same four reconciles with answered hidden, and leave the Waiting on you narrowing standing for the rest of the journey.
Not ticked(page), incidentally, even though the heartbeat is what the earlier thread named: receiveState guards renderPanel() behind eventSeq > runtime.lastEventSeq || activation, so a heartbeat re-applying the state the page already holds never reaches renderThreads. The find box and a growing log are the two doors that do.
# Conflicts: # plugins/leaf/skills/leaf/assets/leaf.js
Corrects a false reason in `ci.yaml`'s workflow-level concurrency comment. It said a push to main keeps its run partly because "a cancellation reaches tend-ci-fix as something to fix". `tend-ci-fix` runs only when `workflow_run.conclusion == 'failure'`, and tend's ci-fix template has no option to widen that, so a cancelled run is never answered. The comment now says a cancellation goes unreported. #2443's description repeated the same claim. ## Issue #74: scheduled `ci` runs cancelled Investigated; the cause was already fixed by #2443 (merged 2026-10-12 00:19 UTC): - Between #751 and #2443, 10 of the 25 daily scheduled runs ended cancelled with no runner (`runner_name` empty): Sep 18, 27, 29 and Oct 2, 3, 5, 6, 9, 10, 11. The scheduled job shared the push queue's concurrency group, and under `queue: single` the next merge replaced the pending scheduled entry. Because `tend-ci-fix` ignores cancelled runs, none of these reached anyone. - #2443 gave the schedule a group of its own (`ci-test-schedule`). The first scheduled run since then, [38239628776](https://github.com/max-sixty/leaf/actions/runs/38239628776), got a runner 4 seconds after it was created. - The account-wide pool is not the cause: when the scheduled runs did reach a runner (Oct 1, 4, 7 and 8), they waited between 18 minutes and 2¼ hours and then ran for 2 to 3 hours. That is well inside the 6-hour job limit. Behaviour changed: none. The change is to a comment only. Hand-written source line delta: +4 −3 (YAML comment). Test line delta: 0. > _This was written by Claude Code on behalf of max-sixty_ Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
An open thread no longer implies that the reader owes another answer. Agent comments still open questions, while ordinary replies remain available for follow-up without entering "Waiting on you" unless sent with
leaf reply --awaits.Structured reply questions keep one authority: open
x-awaitsmarkup enters the waiting list from its standing widget projection, and its recorded answer removes it. Leaf rejects a redundant--awaitsflag beside that markup. Settling reactions continue to acknowledge either kind of request without closing the thread.Closes #52
Thanks to @max-sixty for reporting this in #52.