Skip to content

Stop resetting discarded margin hosts during removal - #3698

Merged
leaf-agent merged 1 commit into
mainfrom
fix/ci-39901745205-margin
Oct 23, 2026
Merged

leaf-agent merged 1 commit into
mainfrom
fix/ci-39901745205-margin

Conversation

@leaf-agent

Copy link
Copy Markdown
Collaborator

Retiring a margin row now releases its layout references without resetting DOM attributes and styles on the host that the projection immediately removes. In main CI run 39901745205, a diff-backed host can be placed and retired within one turn; resetting data-lf-place produced a zero-net write that the browser write watch reported at teardown. The focused reply-session case reproduced that error on current main before the change and passed afterward.

The same change passes affected tab-browsing, seated-thread, and reaction-picker cases locally. The committed browser kernel was rebuilt, and pnpm run test:runtime passed all 533 tests. Refs #3695; the run's other assertions and two diff-summary write errors are outside this PR's scope.

A diff outlet can disappear in the same turn that its margin host was placed. Resetting data-lf-place during unregister then writes a zero-net face before the host is removed, which the browser write watch rejects. Unregister now releases retained layout references and leaves the discarded DOM untouched. The reply-session teardown that failed before this change passes afterward; other affected draft, thread, and reaction cases pass too.
@leaf-agent
leaf-agent merged commit b09f292 into main Oct 23, 2026
4 checks passed
@leaf-agent
leaf-agent deleted the fix/ci-39901745205-margin branch October 23, 2026 06:13
leaf-agent added a commit that referenced this pull request Oct 23, 2026
A deferred diff file without a previous path drew the same path before
and after its evidence was verified, but `paintSummary` keyed those two
states as `false` and `null`. Lit removed and reinserted the unchanged
path node while adding file stats, which the browser write watch
reported in [main CI run
39901745205](https://github.com/max-sixty/leaf/actions/runs/39901745205).
The key now follows the previous path actually shown, so verification
keeps an unchanged path node while a genuine rename can still replace
it.

The two deferred retry tests and the diff recovery test failed before
this change and pass afterward. The existing rename/focus case also
passes, and `pnpm run build:browser` succeeds. Refs #3695; this PR
addresses the diff-summary write errors, separate from the margin-host
repair in #3698.

Co-authored-by: leaf-agent <[email protected]>
max-sixty added a commit that referenced this pull request Oct 25, 2026
Tend now tracks each test failure it leaves unfixed in an issue of its
own, one per test node id, instead of adding rows to whichever `ci-fix:`
issue a run touched first. The rule goes in `running-tend`'s **Fix every
failure in a red run**, the repo overlay that `/tend-ci-runner:ci-fix`
loads. The overlay replaces that skill's tracker per failure shape for
Leaf.

**Why.** #3695 was opened for the declared-scroll-surface regressions
from #3673. Those were repaired by #3697, #3698, #3699, #3705, #3706,
#3724, #3746 and #3758, and the issue then became a per-nightly
umbrella. Its Oct 24 table lists 24 failures from one nightly that share
no cause with its title. Across the Oct 21–24 nightly logs, ten of those
rows failed on every nightly since they first appeared, three to five
nights in a row. They are deterministic regressions in `journeys` tests,
which run only nightly, so the pull requests that caused them passed
their own CI. Inside the umbrella a row had no owner and could stay red
for five nights while the issue looked worked on.

**What the rule says.**

- One `ci-fix:` issue per failing test node id (or per failing check
outside the suite), with the node id in its title. Tend searches open
and closed issues for that id, reuses the one it finds, and reopens it
if closed. Another test's failure never joins it; a fix for a shared
cause closes each test's issue. A failure an open PR covers is that PR's
and needs no issue, as `tests/AGENTS.md`'s ownership rule (from #3939)
already reads. A `test-macos` failure follows the same rule under the
same node id, so one issue holds a test's failures on both jobs, with a
table row per job.
- The body records the first `ci` run on main the test failed in, with
its commit, since that brackets the change that broke it.
- Below that, the failure/status table from #3695's thread: one row per
failure the test reports (its assertion, a watch finding at teardown),
with the status, the PR or run behind that status, and what remains.
Tend edits the body as the status changes and comments only to say what
changed. The run summary uses the same table, one row per failing test
with its issue or PR, and it marks a failure nobody investigated.
- A watch finding that fails on CI and passes locally is reproduced on a
slower CPU, not by reruns. **Reading a red suite** points to
`tests/AGENTS.md` "Races", which owns the `--cpu-throttle` recipe from
#3858.

**Scope.** The triage proposed this for nightly failures. The rule
covers any failing test a session leaves unfixed, push runs included. An
umbrella costs the same whichever run produced it, and a push-run
failure without a fix needs a tracker under the same key. Where a
session fixes a failure in the same run, it files no issue.

This supersedes #3768, the bot's open PR that adds the status table as a
general reporting rule. The table here is the body of each per-test
issue and of the run summary, so #3768 can be closed unmerged. The
**Leave outage trackers** line now says `ci-fix` trackers "name no
stranded trigger" rather than "have no rows", since a `ci-fix` issue now
has table rows.

The edit has no eval. It was checked by reading it against the bundled
`ci-fix` skill's tracker steps (2 and 4b), which it overrides only on
the key and the body.

Changes to agent instructions need the control-plane owner's approval
(**Landing**); Max authorized this PR in the triage brief.

Refs #3695

> _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.

1 participant