Skip to content

fix(macos): refine installation, language switching and disk usage - #16

Draft
danvilig wants to merge 38 commits into
developfrom
codex/macos-installer-repair
Draft

danvilig wants to merge 38 commits into
developfrom
codex/macos-installer-repair

Conversation

@danvilig

@danvilig danvilig commented Nov 17, 2026 •

Copy link
Copy Markdown
Owner

Summary

Repair the Mac installer integrity failure and refine the installation experience based on native acceptance feedback: crisp Retina text, an original guide icon, one selected language across the desktop and tray, a cleanup/uninstall entry, and a smaller native AppKit/WebKit macOS application without bundled Chromium.

Changes

  • Re-sign final assembled native executables and nested bundles inside out. This is still an ad-hoc signed test build without Developer ID/notarization.
  • Replace the 1x Finder background with a multi-representation 1x/2x TIFF, retain the minimal drag layout, and set an original guide icon on the mounted HFS+ image. The offline guide shows one language at a time with a language picker, reduced motion and keyboard support. Source scanning allows four exact original PNG assets and still scans their contents.
  • Persist desktop language independently of gateway configuration, so switching while running preserves gateway PID. Rebuild native status-bar/application menus and confirmation dialogs in the selected language; use ordered OS language preferences for System.
  • Retain background removal and add confirmed cleanup/uninstall: stop owned processes, remove login startup, clear exact app settings/management tokens and Electron storage; on Mac move the application to Trash. Refuse active/uncertain remote deployments and foreign registrations. Preserve projects, Codex credentials, headless deployments, unknown files and stable lock/generation anchors.
  • Replace macOS Electron/Chromium with system AppKit/WKWebView, retain the complete Bun/Node gateway, native PTY and original shared settings renderer. Keep control tokens in Bun helpers with installation ownership checks and registration rollback; restrict WebKit assets to an explicit custom-scheme allowlist and bridge to the main frame/action/size allowlist. Use ephemeral web storage, native menus, confirmations, directory picker and Trash. The background launcher owns an EOF lifetime pipe to the agent. Windows/Linux and portable runtime layouts remain unchanged.
  • Strip bundled Node local/debug symbols before signing, retain runtime notices, and use macOS transparent filesystem compression for the actual app in the DMG. Record logical versus allocated bytes before/after and verify the compressed copy after installation. Increase DMG container compression without treating download size as installed size.
  • Preserve macOS 15.0 minimum and validate the same DMG on macOS 15 and 27. Native tests inspect Retina representations/custom icon metadata, real localized native menus/dialogs, language persistence with a running gateway, and confirmed uninstall against a disposable installed copy. CI retains size reports alongside existing screenshots/evidence.

Verification

Current source head: 5e9730c15e43b68573d864edda6020880d614971.

  • Local bun run check, bun run test:unit (400 passed, 0 failed, 2,388 assertions), bun run test:release, bun run test:portable, PLAYWRIGHT_BROWSERS_PATH=/tmp/crw-playwright bun run test:desktop, node --check tests/browser/macos-native.e2e.mjs, git diff --check and the home-layout checker passed. Both current Verify runs passed: PR 44227929556 and push 44227923105, including offline release gates, desktop/guide UI, Docker and source candidate checks. PR policy passed. The native workflow failed only its two macOS 27 UI jobs, as detailed below; all runs have final conclusions.
  • Latest macOS 15.8.2 (24H232) package job passed in native run 44227929246. Installed logical payload: 199,062,249 bytes; actual Finder-copied allocation: 92,712,960 bytes (previous 223,318,016). DMG: 85,267,954 bytes. SHA-256: af6f29e34ccb63e2a6149925037eb7f3b9951d2a9b93d1d7a177d5d51076023f.
  • The macOS 15 test covers real DMG mount/Finder installation, minimum 15.0, Retina artwork/icon, relocated signatures, gateway/real PTY, actual screen composite and WebKit light/dark snapshots, Chinese/English native menus/dialogs, settings save and language persistence, tray quit with gateway continuity, reconnect/stop, and confirmed cleanup/Trash preserving account/project fixtures.
  • macOS 27 actual-window validation remains unresolved and the PR stays draft. The standard macOS 27.0.1 (26A434) runner renders internal WebKit snapshots/DOM correctly but omits page contents in both screencapture and ScreenCaptureKit. Independent inline/custom-scheme tests reproduce this across data stores, layer hosting, load order, color space, rasterization, explicit display/transaction flush, normal AppKit entry and a signed minimal app bundle. System Safari opening an original local HTML fixture also shows its blue background without its text/input; the screenshot is in the webkit-compositor-diagnostics artifact. This establishes a broader reproduction on that runner, not that this app is proven compatible on another Mac. No private WebKit API or relaxed pixel assertion is used.
  • A GPU-runner comparison never started: GitHub rejected it for billing/spending limits. The user declined GPU use; both jobs are restored to standard xcode-27. No successful GPU result or GPU root cause is claimed. The latest same-DMG macOS 27 job failed its actual-screen pixel assertion; mount, Finder installation, signatures and gateway/PTY checks passed. Its SHA-256 matches the macOS 15 report. Both native macOS 27 jobs failed; Linux x64/arm64, Windows x64 and the macOS 15 package jobs passed.
  • No dual-OS accepted installer is claimed. The local experimental export retains the same-DMG reports, checksums, native screenshots and explicit macOS 27 UI failure instead of relabeling the candidate as accepted.
  • External native test drivers/probes never enter the app. Screenshots/projects/accounts are synthetic. Safari download quarantine, manual Gatekeeper approval and real login/logout remain manual acceptance items.

Risk and rollback

Maintainer attention: packaging/native signing, source-image allowlist, cleanup/execution boundaries and the CI artifact paths. Cleanup requires an explicit in-app confirmation; no user cleanup is executed by development tests. Active remote deployment receipts are retained until managed removal completes, and stable synchronization files intentionally remain. Filesystem compression depends on a compatible APFS/HFS+ destination; logical file size is reported separately. No dependency upgrades, cloud mutations, production restarts, published release changes or protected merges. Revert the PR to restore previous behavior.

AI assistance

Codex implemented and reviewed the changes and ran the listed tests. Original artwork is drawn in code; screenshots use synthetic fixture data. No human review or personal Mac acceptance is claimed. macOS 15 native results passed; macOS 27 actual-window validation remains unresolved; previous artifact results are retained separately; remaining user acceptance includes Safari/Gatekeeper and real login/logout.

Checklist

  • No secrets, private data or proprietary assets included.
  • Reported checks were actually run; skipped checks have reasons.
  • A maintainer will review and merge; AI output is not approval.

@danvilig danvilig changed the title fix(macos): restore app signatures and simplify installation fix(macos): refine installation, language switching and disk usage Nov 17, 2026
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