fix: keep lifecycle window out of Mission Control - #2997
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 16, 2026, 10:34 PM ET / August 17, 2026, 02:34 UTC. ClawSweeper reviewWhat this changesThe PR changes CodexBar’s hidden SwiftUI lifecycle window from floating across all Spaces to normal-level and Space-local, with focused assertions for its inert properties. Merge readinessThis owner-authored PR is a focused, source-consistent fix for the linked Mission Control failure. The remaining uncertainty is affected-OS validation on macOS 27, not a discrete patch defect. Priority: P2 Review scores
Verification
How this fits togetherCodexBar keeps a tiny hidden SwiftUI window alive so native Settings and toolbar scenes remain available after the menu UI moved to AppKit. AppKit configures that window’s WindowServer traits, which affect Spaces and Mission Control. flowchart LR
A[Menu bar app starts] --> B[SwiftUI lifecycle scene]
B --> C[Hidden keepalive window]
C --> D[AppKit window configuration]
D --> E[WindowServer Spaces behavior]
E --> F[Mission Control]
C --> G[Settings and toolbar scenes]
Decision needed
Why: Only an affected macOS 27 environment can directly confirm both recovery from Mission Control dismissal and preservation of the required lifecycle scene behavior. Before merge
Agent review detailsSecurityNone. Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Validate the freshly built bundle on macOS 27, confirming that Mission Control remains open and native Settings and toolbar scenes still work, then merge the narrow fix. Do we have a high-confidence way to reproduce the issue? No for the exact runtime symptom in this review environment: the linked report gives clear macOS 27 steps and current source exposes the matching traits, but the available host is macOS 26. Is this the best way to solve the issue? Yes, conditionally: removing only floating and all-Spaces traits is the narrowest source-consistent response while preserving the lifecycle window’s inert properties; macOS 27 confirmation remains the best final check. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against dbd54a8bcc8e. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
Summary
Why
Reporter diagnostics ruled out activation-policy transitions and the recurring OpenAI web-extras window. The remaining behavior matches CodexBar's alpha-zero, 1×1 lifecycle window being ordered as a floating window across every Space. That WindowServer footprint appears to trigger a macOS 27 Mission Control regression.
The lifecycle scene itself is still required: it keeps SwiftUI's Settings scene alive after the menu UI moved to AppKit. This change therefore leaves the scene ordered, offscreen, transparent, transient, cycle-ignored, and mouse-ignored, while returning it to normal window level and removing all-Spaces membership.
Verification
swift test --filter SettingsWindowOpeningTestsmake checkThe full suite was also attempted with
CODEXBAR_TEST_GROUP_SIZE=6 make test. It advanced through 52 groups before unrelatedCodexUsageFetcherFallbackTestsRPC timing assertions failed on the shared, CPU-constrained host; issue-specific tests remained green.Mission Control on macOS 27 is not reproducible on the available macOS 26.6.1 host. This removes the WindowServer traits that match the reporter's diagnostics, but the result still needs reporter verification on the next macOS 27 build.
Fixes #2955