LearnNewsExamplesServices
Frontmatter
id19868
titleA pane returned by its title bar right after another one can stay in its popup
stateClosed
labels
bugaidashboard
assigneesneo-opus-grace
createdAtOct 19, 2026, 5:55 PM
updatedAtOct 19, 2026, 8:33 PM
githubUrlhttps://github.com/neomjs/neo/issues/19868
authorneo-opus-grace
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtOct 19, 2026, 8:33 PM

A pane returned by its title bar right after another one can stay in its popup

Closed Backlog/active-chunk-9 bugaidashboard
neo-opus-grace
neo-opus-grace commented on Oct 19, 2026, 5:55 PM

Context

Found while proving #19866 (PR #19867), on the v13.3 cut day. In apps/workstation, a pane returned by its OS title bar right after another one can stay in its popup. WorkstationPopupReturnNL.spec.mjs ("a second popped-out pane docks back by its OS titlebar after the first one did") fails 1 of 3 runs when the 1.5 s pause between the two returns is removed. The failing assertion is dwelling over the main window docks alerts home. The merged arm keeps the pause, a human's pace; a fast hand does not.

The Problem

DragCoordinator#commitNativeWindowDrop (src/manager/DragCoordinator.mjs, the embodyNativeHover === true && !preview branch) asks the target for one preview after the park, and a null answer clears the candidate and ends the gesture. While main still projects the first return, it cannot preview yet, so the second drop is abandoned on its first answer: no second ask, no receipt.

The Architectural Reality

  • Design authority: ADR 0029 §2.3 (Cross-Window Drag) and §2.8.6 (in-gesture vessel conversion and park), and the same-target preview→commit contract: a drop commits what its target previewed.
  • DragTarget#answerWhenPreviewable (src/dashboard/dock/window/DragTarget.mjs) covers this gap on the hover path: a frame that got no preview is asked again once awaitPreviewable resolves, while that frame is still current. The committed-drop path does not use it.
  • Precedent for the class: #18054 turned the strict park's first refusal from a terminal into a bounded retry ("a window under a live OS drag" refuses at first); a transient "not yet" is not a verdict.

The Fix

On a null preview, await the target's previewability once through the seam answerWhenPreviewable uses, then ask again while the candidate is still current. Abandon only when that answer is null too.

Contract Ledger

Surface Authority Behavior Fallback Docs Evidence
DragTarget#answerWhenPreviewable(frame) → Promise<preview|null> ADR 0029 §2.3, §2.8.6 Every waiter for that exact frame shares its pending or current answer; DragCoordinator#commitNativeWindowDrop consumes it once after a null native preview A stale, left, destroyed, refused or rejected readiness answers null; a coordinator cancellation or replacement prevents the commit JSDoc CrossWindowDragTarget.spec.mjs and DragCoordinator.spec.mjs arms; the no-pause WorkstationPopupReturnNL arm

Acceptance Criteria

  • Two panes returned by their OS title bars with no pause between the returns both dock (real-browser arm, repeated).
  • A drop whose target still cannot preview once it settles is abandoned as before, and a candidate replaced meanwhile is not committed.
  • Unit arm on DragCoordinator: a null first answer is asked again once the target is previewable.

Out of Scope

  • Pointer (tab-drag) returns: #19866.

Related

#18054, #19866, #19867

Live latest-open sweep: the 25 latest open issues at 15:50Z and open PRs at 15:58Z, no equivalent. A2A claim sweep: the 20 latest messages, none on the dock. MC sweep: "commitNativeWindowDrop null preview abandon", no decision that the abandon is deliberate; #18054 fixed the same class on the park.

Origin Session ID: 89fbb599-fb07-489d-a8ac-b016affdeab0 Retrieval Hint: "second titlebar return while main settles the first is abandoned on a null preview; commitNativeWindowDrop answerWhenPreviewable"

tobiu referenced in commit fbb213d - "fix(dock): a pane returned by its title bar right after another one docks (#19868) (#19870) on Oct 19, 2026, 8:32 PM
tobiu closed this issue on Oct 19, 2026, 8:33 PM