Skip to content

fix: make cmd+w close macos windows - #11399

Closed
didhd wants to merge 1 commit into
kirodotdev:mainfrom
didhd:fix/macos-cmd-w-close-window
Closed

didhd wants to merge 1 commit into
kirodotdev:mainfrom
didhd:fix/macos-cmd-w-close-window

Conversation

@didhd

@didhd didhd commented Sep 16, 2026 •

Copy link
Copy Markdown

Problem / Motivation

On macOS, Cmd+W does not close the focused dashboard window as requested in #11393. The Window menu deliberately leaves the chord to the renderer for session close; it has no native Close command.

CI also inherited Fargate protocol failures (#11417) and ledger test fixtures that no longer satisfy the schema on main (#11439/#11443). These backend failures also prevent Coverage Gate from completing.

Why it matters

The standard macOS window-close shortcut should follow the close button even while the dashboard is loading or its shortcuts are disabled. Closing a secondary window must not silently discard unsaved editor or embedded-browser input.

What changed (motivation → approach → change)

  • Add Electron's native Close role on Cmd+W to the macOS Window menu in website/electron/app-menu.js, preserving Minimize, Zoom, and Bring All to Front. The main dashboard follows its existing hide-to-tray handler, including native fullscreen exit; its gateway and sessions remain alive.

  • In website/electron/window-lifecycle.js, show a native Stay / Close Window confirmation before closing every secondary dashboard window, including a clean or unresponsive dashboard. The detail warns about possible unsaved changes and explains what Stay preserves. It mentions browser pages only when they are open. Stay is both the default and cancel action and preserves every page, control owner, and running browser command channel. Explicit consent releases owners before destroying their pages.

  • Obtain consent before any renderer-close call. Such a call destroys accepting browser pages before a later veto; a dashboard unload handler can also time out and be destroyed before it vetoes. A real Electron 43.2.0 regression reproduced this with a 20-second unload handler: the window disappeared after about one second without a dialog. Remove the dashboard unload probe and its listeners. The trade-off is a confirmation even for clean secondary windows. Main-window hiding and app quit keep their existing paths.

  • Coalesce pending close requests and temporarily refuse creation of new browser pages until the decision completes. Retain the dashboard WebContents reference through teardown, and guard browser-panel, theme, maximize, and fullscreen callbacks when its view has lost that reference.

  • Advertise Option+Shift+W for macOS session close in website/src/lib/shortcutRegistry.ts and stop matching Cmd+W in the renderer. In website/src/hooks/useKeyboardShortcuts.ts, apply the browser-reserved hint only to primary-modifier chords. Windows/Linux retain Ctrl+W for sessions and Ctrl+Shift+W for windows.

  • Cover menu ownership, shortcut matching, confirmation, cancellation, teardown ordering, and renderer lifetime in the Electron tests and website/src/test/shortcutRegistry.test.ts. Update the desktop README and dashboard specification.

  • Include the minimal compatibility repair from fix(cloud): bring the Fargate engine up to the widened LaunchEngine protocol #11422 by pepmach (ab31b00b): src/kiro_crew/cloud/fargate_engine.py accepts the existing login_target protocol keyword and supplies the handle's error field. Default sign-in remains immediate; unsupported named identities return a refusal. Update test/test_fargate_launch_engine.py and docs/system-specs/modules/cloud.md. Fargate is currently unregistered in the shipped provider registry.

  • Align ledger test writers with the existing schema using fix(ledger): make the test writers satisfy the entry registry #11445 by chenmingwei23 (b03365a4): test/test_ledger_kinds.py, test/test_ledger_retention.py, and test/test_remove_slot_for_history_key.py supply required fields and plant deliberately malformed reader input after a valid append. In test/test_ledger_types.py, use the valid crew/report type with src="crew:qa". Production ledger validation is unchanged.

Maintainer decision requested: this intentionally reverses the macOS Cmd+W-closes-session decision recorded in #4608/#9555. #11393 explicitly asks for native window close, but does not itself establish a maintainer-approved replacement session shortcut. Please confirm Cmd+W for the focused window and Option+Shift+W for macOS session close before merge, including the per-platform difference, discoverability, existing custom Cmd+W bindings, and confirmation on clean secondary windows. The title describes a change rather than claiming macOS previously behaved this way.

Tests

  • GitHub CI on ff47b098 finished successfully: backend lint/types, all four Python 3.12 shards, all eight Windows shards, all four frontend shards, Electron, E2E, bundle-size, and Coverage Gate passed. Backend coverage is 92.06% and frontend coverage is 93.38%; both project and per-file gates passed. Desktop builds also passed on macOS, Linux, and Windows. The previous frontend shard 3 worker termination did not recur. UX/First Principles decisions and required maintainer review remain outstanding.
  • Python 3.12.14: the two failing CI test nodes reproduced on untouched base 0c87efad1 and before the compatibility repair. After the repair, 93 Fargate/cloud-launch tests passed, including both failed nodes and unsupported/default identity cases.
  • The five representative ledger failures reproduce on untouched base 04727ebe0f and the preceding PR head: missing required opened/turn/tool fields and a malformed crew type. 964 ledger/core/emitter/reference tests passed after the fixture repairs. The unrelated live-ledger stress test hits this macOS host's 256-file limit on clean base too; it passes on base and this branch with the pytest subprocess limit set to 4,096. No assertions were skipped.
  • Whole-tree flake8, isort, and mypy --platform linux (1,614 source files) passed. Changed Python files pass Black. The unused json import is fixed by inherited upstream fix(dashboard): drop the unused json import left by #9840 #11415.
  • Full Electron suite: 1,925 passed, 1 skipped. This includes 36 affected close/lifecycle tests. The revised consent-before-close regressions fail against the preceding implementation and pass after removing the unload probe.
  • Real Electron 43.2.0 on macOS: 10 native runtime checks passed, including three independent browser WebContents, an attached CDP owner, a dashboard with an unload guard, an already-busy renderer, the native performClose: action, and a real native dialog abort resolving to Stay. Assertions check both dialog descriptions. No gateway requests were made. A separate 22-second observation confirms the slow-unload regression preserves the window and draft on Stay, with zero unload calls.
  • Prior frontend related suite: 7,782 passed across 256 files. This round leaves the previously tested TypeScript shortcut changes unchanged.
  • Build, TypeScript, ESLint, bundle-size (696 chunks), chunk-cycle, documentation, duplication, and whitespace checks passed. The inherited catalog-budget repair on main resolves the previous Bundle Size Gate failure.
  • Local reviews use the extracted CI contracts with default-model reviewers because the pinned GPT/Opus pairing is unavailable in this environment; served model unverified. Both completed their two-stage contracts at ff47b098 and found no Critical/High blockers. The custom Cmd+W-binding migration remains a product-decision advisory. The earlier unverified slow-unload concern was reproduced and repaired as described above.

Manual verification

An isolated macOS Electron harness loads the production menu and createWindowLifecycle factory. It sends the native performClose: action used by the menu role and verifies the resulting window, renderer, form-value, control-owner, and channel state. Dialog responses are controlled for the Stay/Close cases; a separate real native dialog validates BaseWindow compatibility and the cancel result. The existing fullscreen-exit tests cover hide-to-tray behavior.

Runtime menu output, read from the actual Electron Menu:

role=close     label="Close Window"       accelerator=Cmd+W
role=minimize  label="Minimize"           accelerator=CommandOrControl+M
role=zoom      label="Zoom"
role=front     label="Bring All to Front"

Runtime results:

PASS native Window menu roles and Cmd+W accelerator
PASS main window hides with dirty renderer alive, no unload or dialog
PASS Stay preserves dashboard and all 3 browser pages and their input values
PASS Stay preserves attached CDP owner and running browser command channel
PASS repeated close requests share one confirmation
PASS Close Window releases each owner before destroying its page
PASS confirmation precedes dashboard unload; Stay preserves the draft
PASS explicit consent closes dirty and clean secondary dashboards
PASS an already-busy renderer receives confirmation; Stay preserves its draft
PASS real native message-box cancellation resolves to Stay

Slow-unload regression, using a real visible secondary dashboard whose beforeunload handler would run for 20 seconds before vetoing:

Before (a943aec): close requested at 499 ms; window closed at 1504 ms;
                 renderer destroyed at 1506 ms; confirmations=0; draft lost.
After:           close requested and Stay confirmation at 415 ms;
                 after 22 seconds: window alive, renderer alive,
                 confirmations=1, unloadCalls=0, original draft preserved.

Screenshots / video

Native menu verification is supplied as the executable runtime transcript above; no additional screenshots are supplied. Existing macOS shortcut-reference evidence:

Close session is advertised as Option+Shift+W

Close session is advertised as Option+Shift+W on macOS

Related Issues

Addresses #11393. Changes the macOS shortcut decision associated with #4608/#9555, subject to the maintainer confirmation requested above.

Pattern harvest

Rule candidate: review-prompt

Pattern: A WebContents close can destroy accepting or unresponsive renderers before an unload veto arrives. Obtain explicit window-wide discard consent before teardown and retain stable WebContents references through destruction.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

Fixes #11393

@didhd
didhd requested review from a team and hoang-phan98 September 16, 2026 23:16
@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention fork Pull request from a fork (external contributor) readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Sep 16, 2026
@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Fable 5, fork) — 🔴 BLOCK

UX-level review of ff47b098ab560011ff8c076bd2d63b9f5105e89c via the fork AI-review pipeline — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

UX-Verdict: BLOCK

cannot evaluate: missing stills of the Stay/Close Window confirmation (both copy variants) and the macOS Window menu's new Close Window ⌘W entry.

Evidence gaps

  • The secondary-window confirmation dialog ("Close this window?" / "Stay" / "Close Window"), in BOTH detail variants (window-lifecycle.js hasBrowserPages() branch) — no entry in the image list; the runtime transcript in the description is text, not pixels, so it does not close the gap. Close with a screenshot of each native dialog.
  • The macOS Window menu carrying { role: "close", accelerator: "Cmd+W" } (app-menu.js) — the description says "no additional screenshots are supplied"; close with a screenshot of the open Window menu.
  • Shown: the shortcuts reference advertising "Close session ⌥⇧W" (attachment-01.jpg) — that gap is closed.

Watch

  • Cmd+W reverses a shipped habit with no in-app migration: a macOS user pressing their session-close chord now watches the whole main window vanish to the tray, first press, every habituated user. Smallest fix: a one-time hide-to-tray notification naming ⌥⇧W as the new session chord.
  • A user who custom-bound Cmd+W to any renderer shortcut has it silently swallowed by the new menu accelerator — the binding dies with no error. Detect the override and surface the conflict in Settings → Shortcuts.
  • Every clean secondary window now confirms on close (stated trade-off); habituated click-through will erode the guard exactly where it matters. Worth the maintainer decision the PR already requests.

Suggestions

  • Dialog detail line "Choose Stay to keep this window open" restates the Stay button; keep only the pages-will-continue clause in the browser-pages variant and drop the sentence in the plain variant.

[UX-REVIEWED] ff47b09

@github-actions github-actions Bot removed the readiness: checking Automated validation is still running label Sep 16, 2026
@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Fable 5, fork) — 🟡 CONCERNS

Design-level review of ff47b098ab560011ff8c076bd2d63b9f5105e89c via the fork AI-review pipeline — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: CONCERNS

This intentionally reverses the pinned #4608/#9555 Cmd+W-closes-session decision, and the PR itself says it must not merge without maintainer sign-off.

Watch

  • The registry/menu tests that pinned "Cmd+W reaches the renderer" are rewritten to the opposite behavior. The PR correctly treats that pin as a decision, not a gap, and requests confirmation ("Please confirm Cmd+W for the focused window and Option+Shift+W… before merge") — but nothing in the diff enforces that pause, so an ordinary merge lands the reversal, breaks macOS users' session-close muscle memory, and silently eats any custom Cmd+W override (the menu accelerator now fires before the renderer sees the keystroke).
    Clears when: a maintainer explicitly approves the Cmd+W/⌥⇧W split, including the custom-binding and per-platform-divergence questions the description lists.
  • The PR bundles two unrelated cherry-picks — fargate_engine.py login_target compat (fix(cloud): bring the Fargate engine up to the widened LaunchEngine protocol #11422, production code) and the ledger fixture repairs (fix(ledger): make the test writers satisfy the entry registry #11445) — to unblock CI. If those PRs land on main first, this branch double-applies or conflicts; if this merges first, the original authors' PRs go stale, and the window-close change can't be cleanly reverted without dragging backend fixes with it.
    Clears when: the branch rebases onto main once #11422/#11445 merge and drops those hunks, or a maintainer explicitly accepts the bundle as the CI-unblocking vehicle.

Suggestions

  • The always-confirm dialog on clean secondary windows is the documented trade-off for the unverifiable renderer-probe hazard; if maintainers find it too noisy, a renderer-push dirty flag (renderer notifies main on state change, no close-time probe) preserves the no-probe invariant without the clean-window prompt — follow-up, not this PR.

[DESIGN-REVIEWED] ff47b09

@github-actions github-actions Bot added the readiness: action required A blocking check or review needs attention label Sep 16, 2026
@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

GPT 5.6 Review (fork) — ✅ no blocking findings

Reviewed ff47b098ab560011ff8c076bd2d63b9f5105e89c via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] ff47b09

@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Fable 5, fork) — 🔴 BLOCK

Premise-level review of ff47b098ab560011ff8c076bd2d63b9f5105e89c via the fork AI-review pipeline — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

First-Principles-Verdict: BLOCK

The macOS Cmd+W/⌥⇧W swap reverses the recorded #4608 decision with no accepted RFC — the description itself asks a maintainer to decide it.

Not justified as shipped

  • Item 1 — product-shape, no recorded decision: replaces what Cmd+W does by default on macOS, reversing the pin the diff deletes ("no Close entry, so Cmd+W reaches the renderer", citing Make built-in keyboard shortcuts rebindable — fixed Option/Ctrl chords collide with macOS cursor movement #4608); the description concedes Cmd+W does not close the main dashboard window on macOS #11393 "does not itself establish a maintainer-approved replacement session shortcut".
    Clears when: an RFC covering this shortcut shape merges non-draft on base and the author pushes or rebases, or a maintainer pushes this branch to kirodotdev/KiroCrew and records /ai-review override first-principles ff47b098ab560011ff8c076bd2d63b9f5105e89c: <decision>.
  • Item 2 — unjustified move: session close relocated to Option+Shift+W solely to free Cmd+W; it stands or falls with item 1.
    Clears when: the same record as item 1.
  • Item 6 — rides along: the browser-reserved narrowing exists only so the moved ⌥⇧W chord can be advertised.
  • Item 7 — rides along: Fargate login_target/error repair; derived — base launch_job.py:488 already declares error, so the protocol test is red on base.
  • Item 8 — rides along: ledger fixture repairs; derived — base entry_types.py:156-218 requires the fields the old fixtures omit, and crew:qa fails schema.py:171.

What this change ships

Inventory (9 items) — 4 justified

Intent: let macOS users close the focused dashboard window with Cmd+W (#11393) — a FIX, carrying two CI-unwedge riders.

  1. Cmd+W on macOS now closes the focused window, not the chat session — product-shape, no recorded decision
  2. macOS session close moves from Cmd+W to Option+Shift+W — unjustified move (rides on item 1's decision)
  3. Every secondary window close now shows a Stay/Close confirmation, even when clean — justified
  4. New browser pages are refused while a close decision is pending — justified
  5. Theme/fullscreen/maximize/panel callbacks tolerate a destroyed dashboard renderer — justified
  6. Shortcut reference marks only primary-modifier chords browser-reserved — rides along
  7. Fargate sign-in accepts login_target, refuses non-default identities — rides along (unwedges red base build)
  8. Ledger tests supply registry-required fields, planting malformed reader input post-append — rides along (unwedges red base build)
  9. Desktop README and two specs updated with the new behavior — justified

Blockers

product-shape change without accepted RFC — the default meaning of Cmd+W on macOS. The diff deletes the pin "macOS keeps the stock Window menu (Minimize, Zoom, Front — no Close entry, so Cmd+W reaches the renderer)" and rewrites the test citing #4608; the description says "Maintainer decision requested: this intentionally reverses the macOS Cmd+W-closes-session decision recorded in #4608/#9555 … Please confirm … before merge". The base RFC list (all 50 entries read) names no RFC covering desktop shortcuts or window close, so the proposal has no recorded decision; the requested decision also covers the new clean-window confirmation (item 3).
Clears when: an RFC covering the Cmd+W-closes-window / Option+Shift+W-closes-session shape merges non-draft on the base branch and the author pushes or rebases, or a maintainer pushes this branch to kirodotdev/KiroCrew and records /ai-review override first-principles ff47b098ab560011ff8c076bd2d63b9f5105e89c: <decision>.

[FIRST-PRINCIPLES-REVIEWED] ff47b09

@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

Opus 4.8 Review (fork) — ✅ no blocking findings

Reviewed ff47b098ab560011ff8c076bd2d63b9f5105e89c via the fork AI-review pipeline; updated in place on each push.

Review details

The candidate list found no candidates. My independent examination confirms the substantive changes are sound:

  • fargate_engine.py: run_launch reads handle.error first (launch_job.py:722-786) and marks the sign-in step FAILED, records job.error, returns FAILED — the non-default-target refusal is correctly wired, not swallowed.
  • shortcut registry / useKeyboardShortcuts.ts: browserReserved && chord.mod gate correctly de-reserves the macOS ⌥⇧W close-chat chord (no mod) while keeping new-chat and the Windows/Linux Ctrl+W reserved; matches the test assertions.
  • window-lifecycle.js / app-menu.js: the setupWindowClose teardown, the !view.webContents/isDestroyed() guards, and the native Cmd+W menu entry are internally consistent and covered by the extensive new test file with no unguarded double-teardown or unconfirmed data-loss path.

No grounded, reachable defect surfaced in the changed lines to add under Step 2.

No findings.

[OPUS-REVIEWED] ff47b09

@didhd didhd changed the title fix: restore cmd+w window closing on macos fix: make cmd+w close macos windows Sep 17, 2026
@didhd
didhd force-pushed the fix/macos-cmd-w-close-window branch from 77898c7 to e1ddef2 Compare September 17, 2026 00:22
@github-actions github-actions Bot added readiness: checking Automated validation is still running readiness: action required A blocking check or review needs attention and removed readiness: action required A blocking check or review needs attention readiness: checking Automated validation is still running labels Sep 17, 2026
@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

fixed

Fixed in e1ddef253b6790d905204da93c44dcb1ea7cb340. Secondary windows with live embedded browser pages now require explicit window-wide discard consent before ANY renderer is closed.
Stay is the default and cancel action and preserves the dashboard, every embedded form, control owners, and ongoing browser work. Close Window explicitly covers unsaved changes in all pages.
Closing WebContents to probe their guards would destroy clean pages before a later veto; this path instead obtains consent first, including for clean embedded pages. New page creation is refused while that decision is pending.
Verified with 1,925 passing Electron tests (one skipped) and real Electron 43.2.0/macOS: two earlier pages plus a dirty final page retain their inputs and attached CDP owner on Stay; explicit Close releases owners before their pages.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

fixed

Fixed in e1ddef253b6790d905204da93c44dcb1ea7cb340. A dashboard beforeunload veto now opens the native Stay / Close Window confirmation instead of silently ignoring the command.
The native veto remains in force while the dialog is open. Stay is both defaultId and cancelId; Close Window explicitly consents to discarding unsaved dashboard/browser input.
A real Electron renderer veto, preservation on Stay, successful retry, and actual native message-box cancellation to Stay were exercised on macOS.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please confirm that #11393 supersedes the macOS session-close choice recorded in #4608/#9555 and approves Cmd+W for the focused window with Option+Shift+W for session close.
The PR body explicitly identifies this as an intentional product decision reversal. Main-window close hides to the tray; secondary-window discard requires confirmation when browser pages or unsaved editor changes exist.
No maintainer approval or policy override is being claimed by this update.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please confirm that #11393 authorizes giving macOS Cmd+W to native window close in place of the session-close decision in #4608/#9555.
The description now names the prior decision, and the title is "fix: make cmd+w close macos windows" so it makes no claim that this restores earlier macOS behavior.
The requested product confirmation remains outstanding before merge.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please confirm Option+Shift+W as the macOS session-close default coupled to assigning Cmd+W to native window close.
This exception to the prior primary-modifier convention is explicit in the PR description. The issue states the native window-close request but does not independently establish maintainer approval of the replacement session chord.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

fixed

Addressed for e1ddef253b6790d905204da93c44dcb1ea7cb340 in the regenerated PR description and owning dashboard specification.
They explicitly name the browser-panel notification guard and the theme, maximize, and fullscreen guards. A retained native window can outlive dashboard WebContents; these callbacks must tolerate WebContentsView dropping its webContents reference while a close decision is pending.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

Native runtime evidence for the macOS Window menu and close behavior at e1ddef253b6790d905204da93c44dcb1ea7cb340 is now in the PR description. The contributor requested execution evidence instead of additional screenshots.

The actual Electron 43.2.0 Menu reports Close Window / Cmd+W, Minimize, Zoom, and Bring All to Front. An isolated harness uses the production menu and window lifecycle, invokes macOS performClose:, and verifies real renderer/form state rather than only checking a menu template.

Nine native checks pass, including Stay preserving three browser pages and their input values plus an attached CDP owner, explicit consent releasing owners before destroying pages, main-window hide-to-tray, and a real native dialog cancelling to Stay. This is executable functional evidence; no new menu screenshot is claimed.

@didhd
didhd force-pushed the fix/macos-cmd-w-close-window branch from e1ddef2 to 64b2411 Compare September 17, 2026 01:19
@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

fixed

Fixed in 64b241135968383bf2351cdfd17b4b3f51e1fa0c. The detail now says: "Any unsaved changes in this dashboard and its browser pages would be lost."
The conditional wording also applies to clean windows. The always-confirm trade-off remains explicit and is separately presented for maintainer acceptance.
The 36 affected Electron tests and all nine native macOS runtime checks pass with this copy.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please weigh the macOS habit change and decide whether the proposed native Cmd+W default requires an in-app migration cue before adoption.
The main-window action preserves running sessions and the replacement chord is documented in the shortcut reference. The PR explicitly awaits your approval of the changed default; it does not claim that the habituation cost has been accepted.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Sep 17, 2026
@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please decide whether the Cmd+W window-close / Option+Shift+W session-close change requires a first-use tray notification or migration cue before merge.
The prior habit and its deliberate reversal are explicit in the description. No in-app migration cue or user-comprehension result is being claimed.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please decide how existing macOS Cmd+W overrides should be migrated or flagged in the shortcut editor when the native menu takes ownership.
The accelerator consumes the chord before renderer shortcuts. This limitation remains part of the requested product decision, including custom panel bindings; it has not been described as already repaired.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please explicitly accept confirmation for every secondary window, including clean windows and its habituation trade-off.
The real Electron slow-unload case lost a draft before its veto arrived. Consent before any renderer close preserves the whole window on Stay and avoids that destructive probe; the main dashboard still hides without confirmation.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

rebutted

The detail deliberately spells out the result of the default/cancel action while the preceding sentence warns about losing changes. It also explains that existing browser work continues on Stay.
Keeping this short explanation is a copy choice, not a remaining correctness defect. The explicit result of Stay is useful alongside the loss warning, so the documented wording is retained for this nonblocking copy suggestion.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please explicitly approve the Cmd+W / Option+Shift+W split, the per-platform difference, and the treatment of custom Cmd+W bindings.
The PR names #4608/#9555 as the decision it proposes to change. Required readiness and human review are still uncleared; no merge or product approval is being claimed.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please accept carrying the declared #11422 and #11445 repairs here, or merge those focused PRs first so this branch can rebase and drop their changes.
Both repair families fix failures reproduced on clean main. Their authors and source SHAs are credited, the ledger changes are test-only, and the shared revert/conflict trade-off is acknowledged. At the latest refresh both source PRs remain open.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

rebutted

A renderer-pushed dirty-state protocol is a possible independent optimization, not needed to make this close path preserve data. It would need an aggregate of every editor plus conservative unknown and unresponsive states.
The current confirmation preserves the no-probe rule and is verified with a busy renderer. Its clean-window cost is declared for the maintainer decision; a new IPC state protocol would widen this repair without resolving a remaining blocking defect.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please record the macOS Cmd+W window-close decision through an accepted RFC on base or the supported maintainer-owned branch override route.
The issue is a request for the behavior, not an accepted decision. The description identifies the prior pin and asks for approval; the fork author cannot grant that approval.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please explicitly name Option+Shift+W as the approved macOS session-close replacement in the same shortcut decision.
This is the paired consequence of reserving Cmd+W for the native window. The PR acknowledges the earlier convention and does not present the replacement as already approved.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please include the shortcut-reference treatment of Option+Shift+W in the paired default-chord decision.
The hint change follows the proposed chord: it avoids labeling a chord without the primary modifier as browser-reserved. It is declared in the description and remains coupled to approval of that shortcut shape.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please accept the #11422 Fargate compatibility repair in this branch, or merge the focused source PR so this branch can drop it.
The missing login_target/error protocol members fail on clean main as well as the PR. The copied repair passes all 93 focused Fargate/cloud-launch tests and does not register Fargate in the shipped provider registry.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please accept the declared ledger fixture repair here, or merge the focused source repair before this branch rebases.
The fields missing from old test writers and the malformed crew type reproduce on clean main. The repaired fixture uses type crew/report with src crew:qa; production schema and ownership validation remain unchanged. All 964 related tests pass, including the deliberately malformed reader cases.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

needs-a-decision

Maintainers: please provide the accepted RFC on base or use the supported maintainer-owned branch decision route for Cmd+W window close, Option+Shift+W session close, and the documented secondary-confirmation trade-off.
No accepted shortcut RFC or maintainer product sign-off has been found. The PR remains a proposal, and this author has not attempted to waive its required review gates.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

UX evidence gap — native confirmation variants at ff47b098ab560011ff8c076bd2d63b9f5105e89c.

Maintainers: please decide whether the supplied executable native text evidence is acceptable without new dialog screenshots. Both detail variants, Stay/default/cancel, explicit close, and actual native dialog cancellation were exercised. The PR also records preservation with a busy renderer and a 20-second unload handler. These results verify behavior; they do not claim a visual inspection. No additional screenshots are being supplied.

@didhd

didhd commented Sep 17, 2026

Copy link
Copy Markdown
Author

UX evidence gap — native Window menu at ff47b098ab560011ff8c076bd2d63b9f5105e89c.

Maintainers: please decide whether the actual Electron Menu role/label/accelerator transcript and native performClose: execution are acceptable evidence for the added Close Window Cmd+W command alongside Minimize, Zoom and Bring All to Front. No new menu image is provided. The existing shortcut-reference image remains, and the visual menu requirement is explicitly unresolved rather than self-waived.

@github-actions github-actions Bot added the merge conflict Branch has merge conflicts with its base — author must resolve before merge label Sep 17, 2026
@dwu96 dwu96 added the needs-pr-triage PR scanner: awaiting automated triage label Sep 20, 2026
@NicholasRBowers NicholasRBowers added needs-author-decision PR blocked on author input and removed needs-pr-triage PR scanner: awaiting automated triage labels Sep 20, 2026
@NicholasRBowers

Copy link
Copy Markdown
Contributor

🤖 Kiro Crew [operator: NicholasRBowers#a942f9ca]: This PR has been inactive with a merge conflict against main. I reviewed the blockers, and they are not mechanical — they need a maintainer product decision rather than a code fix:

  • First Principles Review is BLOCKing on the shortcut shape itself. Making Cmd+W close the window (and moving session close to Option+Shift+W) reverses the decision recorded in Make built-in keyboard shortcuts rebindable — fixed Option/Ctrl chords collide with macOS cursor movement #4608. Its own clear condition is an accepted RFC merging on base, or a repository writer recording /ai-review override first-principles <sha>: <decision>. Neither is something this PR or the pipeline can supply.
  • UX Review is BLOCKing on two paired calls: whether the changed chord needs a first-use migration cue, and whether it is acceptable that the native menu accelerator consumes Cmd+W ahead of any user-defined override in the shortcut editor.
  • The confirmation dialog on every secondary-window close, including clean windows, is a declared habituation trade-off still awaiting explicit sign-off.
  • The branch carries repairs copied from fix(cloud): bring the Fargate engine up to the widened LaunchEngine protocol #11422 and fix(ledger): make the test writers satisfy the entry registry #11445, both still open. Either those merge first and this branch rebases and drops them, or a maintainer accepts carrying them here. That choice changes what the conflict resolution should look like, so resolving the conflict before it is settled would be guesswork.
  • The behavior is macOS-window-manager specific and cannot be verified from this pipeline's Linux host, so I would be pushing changes I cannot confirm.

To be clear about what I am not saying: nothing here looks wrong. CI is otherwise green, Opus found no blocking findings, and your dispositions already ask maintainers these exact questions. The PR is waiting on an answer, not on work.

Once the shortcut decision is recorded — or those two source PRs land and this branch rebases — the pipeline will re-assess on its next cycle. Add pr-no-autofix if you would prefer it left alone entirely.

Copy link
Copy Markdown
Contributor

PR triage (2026-10-05), checked against origin/main @ a92dde1a. Classification: PARTIALLY_COVERED, plus a BREAKING_CHANGE that is already flagged. Recommendation: REBASE, then wait on the maintainer decision this PR already asks for.

@iamwhatever

Copy link
Copy Markdown
Contributor

Thank you @didhd for the thorough work, especially the unsaved-input protection and the real Electron reproduction. We are closing this PR because Cmd+W on macOS is now intentionally the close-session shortcut (from #9555), and this change would reverse that without a design decision; the bundled backend fixes have also already landed on main. The window-close problem stays tracked in #11393. A small follow-up that adds a Close Window item on Cmd+Shift+W to the macOS Window menu, matching the Ctrl+Shift+W choice on Windows/Linux, would be very welcome.

@iamwhatever iamwhatever closed this Nov 1, 2026
@github-actions github-actions Bot removed the readiness: action required A blocking check or review needs attention label Nov 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fork Pull request from a fork (external contributor) merge conflict Branch has merge conflicts with its base — author must resolve before merge needs-author-decision PR blocked on author input

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cmd+W does not close the main dashboard window on macOS

5 participants