Skip to content

fix(app): close = quit on platforms without the macOS tray - #9

Closed
NestorCanales wants to merge 1 commit into
mainfrom
fix/windows-close-quits
Closed

fix(app): close = quit on platforms without the macOS tray#9
NestorCanales wants to merge 1 commit into
mainfrom
fix/windows-close-quits

Conversation

@NestorCanales

Copy link
Copy Markdown
Collaborator

Bug

HideWindowOnClose: true was set for all platforms, but the tray it pairs with (Show/Quit status-bar menu) is macOS-only. On Windows/Linux, closing the window produced an invisible zombie process — no window, no tray icon, no way to quit short of Task Manager. Each relaunch stacks another instance; they contend for the single-writer SQLite DB.

Observed live in the Phase 5 Windows field test: six concurrent instances accumulated over a day of normal open/close usage, degrading indexing (lock contention) and confusing every diagnostic step.

Fix

HideWindowOnClose: runtime.GOOS == "darwin" — macOS keeps its hide-to-tray workflow unchanged; everywhere else, close quits (the standard platform convention anyway).

Verification

Build/vet/tests green. Behavioral test needs a Windows GUI session — verified manually during the field test cleanup (post-fix build: closing the window terminates the process).

Independent of the epic stack — based on main, mergeable anytime.

🤖 Generated with Claude Code

…nto)

HideWindowOnClose was unconditionally true. It pairs with the macOS
status-bar tray (Show/Quit menu) — but the tray is darwin-only ObjC
(tray.go), so on Windows/Linux closing the window left an invisible
process with no way to surface or quit it. Users relaunch, instances
stack, and the zombies contend for the single-writer SQLite DB: the
Phase 5 Windows field test accumulated SIX concurrent instances, which
also degraded indexing. Close now quits everywhere except macOS, where
the tray workflow is unchanged.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
NestorCanales added a commit that referenced this pull request Jul 27, 2026
Conflict resolution: epic main.go imports gained "runtime" only (strconv
moved to app.go in the epic); the merged visibility-fix regression test
updated to the epic's renamed mock field (EmbedFn -> EmbedDocumentsFn).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@NestorCanales

Copy link
Copy Markdown
Collaborator Author

Consolidated into #2 (single reviewable branch per Bo's review-workflow preference) — all commits from this PR are now in feat/local-embeddings.

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