LearnNewsExamplesServices
Frontmatter
id20033
titleThe overflow-menu spec snapshots its partition before the menu owns it
stateClosed
labels
bugaitestingdashboard
assigneesneo-opus-ada
createdAtOct 23, 2026, 9:29 AM
updatedAtOct 23, 2026, 1:30 PM
githubUrlhttps://github.com/neomjs/neo/issues/20033
authorneo-opus-ada
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtOct 23, 2026, 1:30 PM
milestonev13.3.1

The overflow-menu spec snapshots its partition before the menu owns it

Closed Backlog/active-chunk-10 bugaitestingdashboard
neo-opus-ada
neo-opus-ada commented on Oct 23, 2026, 9:29 AM

Context

A v13.3.1 AC-2 roving specimen (D#19994 discussioncomment-19133550, cut record #20022). WorkstationMaximizeOverflowMenuNL › "docked control arm: clicking More tabs keeps the overflow menu open, focused, and partition-stable until selection" went red in a full e2e/workstation + e2e/dashboard run and is green alone. The appliedHiddenIds assertion passed. The visible-headers assertion failed: with the menu open, the DOM showed one header fewer while the plugin's appliedHiddenIds still equalled the pre-open set. The cut lead's triage: one ticket per cause.

Observed (Vega's run): the red and its signature. Not retained: which header vanished. Measured (6× CPU throttle, AC-2): two mechanisms, below.

The Problem

Corrected 2026-10-23, before any PR, per AC-2's own clause. The first version inferred one cause from a code read. The throttled measurement confirmed it and found a second, more frequent one that the inferred fix does not cover. Both pass the worker-only gate, and neither is a product defect.

waitForOverflowSettled gates the pre-open snapshot on worker flags only: measuring === false, projectQueued === false, and a non-empty appliedHiddenIds. It then reads the DOM-visible headers and compares them, and appliedHiddenIds, with the open-menu state.

(A) The DOM lags the published split. This is the specimen's signature. Overflow#project calls applySplit, which hides headers through button.hidden = true, a vdom update it does not await, and sets appliedHiddenIds synchronously. project() then releases measuring in its finally. So the gate can pass while a header's removal is still in flight. The snapshot then lists a header the worker already treats as hidden. With the menu open it vanishes, and appliedHiddenIds stays the same. Measured in one of three instrumented runs: neo-tab-header-button-5 was in the applied set (11 ids) and still rendered at the snapshot.

(B) The strip re-partitions after the gate and before the menu opens. The spec's pane-body click reveals the focus-gated actions in the DOM. The plugin learns their width only from their own resize events (Toolbar#onActionResize → actionGeometryChange → Overflow#onActionGeometryChange). Under load those events can arrive after the gate has seen an idle plugin.

Instrumented run: the last pass before the snapshot measured one action (the 24 px control) for a 355 px extent and hid 10 tabs. About 400 ms later on the app-worker clock, the four revealed actions' resizes arrived; the next pass measured 120 px of actions, a 259 px extent, and hid 11. That was still before the menu opened, so the menu opened with 11 items against a 10-id snapshot.

On dev at 6× this fails the docked arm 8/8, at itemCount. No DOM gate can see it, because nothing in the worker or the DOM marks a resize that has not been delivered.

A re-partition while the menu is closed is legitimate. An open menu parks every projection: applySplit has one caller, behind queueOpenMenuProjection. So the partition the contract protects is the one the menu opened against, not a pre-click read.

The Architectural Reality

  • src/tab/plugin/Overflow.mjs:
    • applySplit sets button.hidden / button.show() per header, then me.appliedHiddenIds = [...hidden]. project()'s finally sets me.measuring = false, and publishProjectionState() fires overflowProjectionIdle.
    • onActionGeometryChange projects on each action's rendered resize.
    • queueOpenMenuProjection parks every projection while the menu is shown or mounted.
  • src/toolbar/Base.mjs: onActionResize fires actionGeometryChange from each action root's DOM resize.
  • test/playwright/e2e/workstation/WorkstationMaximizeOverflowMenuNL.spec.mjs: waitForOverflowSettled reads only the plugin's state. assertOverflowMenuHoldsAndSelects snapshots appliedHiddenIds and preVisibleHeaders before clicking the control.
  • Precedent: #20020 / PR #20021 settled WorkstationTabDragHeadersStayNL on the DOM and the worker state together.

The Fix

Spec-only.

  • waitForOverflowSettled also polls until the DOM shows appliedHiddenIds: a hidden id has no rendered box, and every other id has one. This covers (A).
  • assertOverflowMenuHoldsAndSelects takes the partition snapshot (appliedHiddenIds and the visible headers) once the menu is visible and settled, then holds 350 ms and compares. This covers (B). The focus-gated action ids stay compared with the pre-click read, because focus never leaves the pane.

Acceptance Criteria

  • Both arms take their partition snapshot once the menu is open and the DOM shows appliedHiddenIds. The action ids stay compared with the pre-click read.
  • At 6× CPU throttle (the instrument #18721 used), the docked arm reproduces the red on dev with its mechanism recorded (vanished header inside or outside appliedHiddenIds). With the fix, both arms are green N/N, and the maximized arm still goes red with #19984's DomAccess fix reversed. (Amended 2026-10-23: the original asked only for the inside-the-set signature.)
  • A disposition naming the cause is recorded on #20022 for the AC-2 line.

Out of Scope

Whether overflowProjectionIdle / whenProjectionIdle should wait for the DOM or for undelivered action resizes. Both production consumers (the dock MotionSignal and the tab SortZone drag start) read that edge. A drag parks projections itself (queueSortDragProjection). It becomes its own ticket only if a falsifier shows a consumer harmed.

Related

Live latest-open sweep: checked latest 20 open issues at 2026-10-23T07:28:40Z; no equivalent found. A2A claim sweep (all read-states, last 25): only my own lane-claim MESSAGE:d18626d6. MC sweep "overflow menu open header disappears … appliedHiddenIds unchanged flaky full run": prior art #19984, #18721; no prior decision on this specimen. Own-assignment sweep: none overlapping.

Origin Session ID: d373d94f-3d91-4a15-a181-4309706acfb5 Retrieval Hint: "overflow settle gate worker flags before DOM split lands WorkstationMaximizeOverflowMenuNL docked arm; revealed action resize re-partitions after idle gate"

tobiu referenced in commit 8eacfb4 - "test(e2e): hold the overflow-menu partition the menu opened against (#20033) (#20039) on Oct 23, 2026, 1:30 PM
tobiu closed this issue on Oct 23, 2026, 1:30 PM