Skip to content

[codex] Document macOS automation sandbox launch#3747

Merged
ten9876 merged 1 commit into
aethersdr:mainfrom
rfoust:codex/automation-macos-sandbox-docs
Jun 23, 2026
Merged

[codex] Document macOS automation sandbox launch#3747
ten9876 merged 1 commit into
aethersdr:mainfrom
rfoust:codex/automation-macos-sandbox-docs

Conversation

@rfoust

@rfoust rfoust commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

Summary

Documents the macOS automation-bridge launch constraint observed under Codex-style sandboxed execution. The sandboxed Cocoa launch can abort during QApplication startup before AetherSDR reaches the automation bridge, and forcing QT_QPA_PLATFORM=offscreen inside the same sandbox still prevents the bridge from binding its QLocalServer socket. The doc now gives the supported headless automation launch command: run outside the command sandbox with QT_QPA_PLATFORM=offscreen AETHER_AUTOMATION=1.

Constitution principle honored

Principle XII - this treats the sandbox boundary as infrastructure behavior, not something AetherSDR can reliably recover from after Qt aborts before app code runs.

Test plan

  • Local build passes (cmake --build build)
    • cmake -B build -G Ninja -DCMAKE_BUILD_TYPE=RelWithDebInfo
    • cmake --build build --target AetherSDR --parallel
  • Behavior verified on a real radio if applicable
    • Not applicable; docs-only launch guidance, no radio connection required.
  • Existing tests pass (CI)
    • Not run locally beyond build and focused launch probes.
  • Reproduction steps documented if user-reported bug
    • Reproduced sandboxed macOS launch abort with AETHER_AUTOMATION=1.
    • Confirmed unsandboxed QT_QPA_PLATFORM=offscreen AETHER_AUTOMATION=1 launch answers tools/automation_probe.py ping.

Additional checks:

  • git diff --check

Checklist

  • Commits are signed (docs/COMMIT-SIGNING.md)
  • No new flat-key AppSettings calls - use nested-JSON-under-one-key
    (Principle V)
  • Code is clean-room - not decompiled, disassembled, or
    reverse-engineered from a proprietary binary (Principle IV)
  • All meter UI uses MeterSmoother (AGENTS.md convention)
  • Documentation updated if user-visible behavior changed
  • Security-sensitive changes reference a GHSA if applicable
    • Not applicable.

@rfoust rfoust requested a review from a team as a code owner June 22, 2026 23:31
Copilot AI review requested due to automatic review settings June 22, 2026 23:31

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Documents a macOS-specific constraint for launching the in-process automation bridge under “Codex-style” sandboxed command execution, clarifying the supported headless invocation so agents can reliably bring up the QLocalServer-based control channel.

Changes:

  • Adds macOS guidance warning that sandboxed Cocoa startup can abort before the bridge initializes.
  • Notes that QT_QPA_PLATFORM=offscreen does not overcome sandbox restrictions on the bridge’s QLocalServer socket.
  • Provides the supported headless macOS launch command to run outside the command sandbox.

@aethersdr-agent aethersdr-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed — docs-only change to docs/automation-bridge.md, and it looks good.

Accuracy & placement:

  • The new paragraph sits naturally right after the existing headless/CI QT_QPA_PLATFORM=offscreen note, which is exactly where a reader hits the sandbox question.
  • The launch command matches the Quickstart's macOS form (./build/AetherSDR.app/Contents/MacOS/AetherSDR) and the same AETHER_AUTOMATION=1 / QT_QPA_PLATFORM=offscreen env vars used elsewhere in the doc — no drift.
  • The QLocalServer socket reference is consistent with the transport section ("Transport: a QLocalServer … AF_UNIX socket on macOS"), so the explanation of why the sandbox blocks the bridge is correct.

Scope: single file, additive (+10/-0), no flat-key AppSettings, no code paths touched — nothing outside the stated scope.

One small nit (non-blocking): the guidance is specific and useful, but if there's a known minimum macOS/Codex sandbox config where it does work, a one-line "if you must sandbox, grant X" would round it out. Not required — documenting the supported path is the right call.

Thanks for capturing this, @rfoust — sandbox-launch failures are exactly the kind of thing that's frustrating to rediscover, and the reproduction notes in the PR body are a nice touch.


🤖 aethersdr-agent · cost: $2.8502 · model: claude-opus-4-8

@ten9876 ten9876 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving — accurate, well-placed docs-only addition. The macOS sandbox caveat is consistent with the doc's Transport section (QLocalServer AF_UNIX socket) and reuses the established env vars + launch-command form, no drift. Documents the supported headless path, which is the right call. CI green. Thanks @rfoust — exactly the kind of gotcha worth capturing.

@ten9876 ten9876 merged commit 588fa82 into aethersdr:main Jun 23, 2026
4 checks passed
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.

3 participants