GeezerVison is showing github.com — fix(cli): treat a Desktop-supervised runtime as the authority in status, doctor and resolve by lidge-jun · Pull Request #6802 · lidge-jun/opencodex
Conversation
Summary
When OpenCodex Desktop starts its bundled runtime itself (the normal case after installing the app), the ocx CLI did not know. Unless a durable ownership claim existed, ocx status reported protection none and told the user to run ocx service install. That would add a second supervisor competing with the app. On the reporting Mac (Desktop 2.81.0, child /Applications/OpenCodex.app/Contents/MacOS/ocx start --port 10100, ownership none because a stale dev-install service record blocks takeover), the output was:
Restart safety: AT RISK after restart (no viable background service; run 'ocx service install')
With this change the same machine reports:
Runtime supervisor: OpenCodex Desktop (pid 36806, /Applications/OpenCodex.app/Contents/MacOS/opencodex-desktop); durable owner: none
Restart safety: AT RISK after restart (OpenCodex Desktop runs this proxy, but its Start at Login could not be verified; turn it on in the OpenCodex menu)
Service: OpenCodex Desktop supervises the running proxy; local startup reports service absent, not running, not viable
What changed:
- Evidence (
src/service/desktop-supervision.mjs, plain ESM so the Node launcher can use it next): the live runtime's direct parent must be opencodex-desktop and the runtime must be that app's sibling ocx. The whole snapshot is read twice. The pid file, runtime-port.json pid and the identity-checked live pid must agree, otherwise the result is unknown. The attestation secret is never read into a result. macOS and Linux only; Windows reports unsupported and keeps today's behavior.
- Separate from ownership: supervision never becomes a durable claim and never changes takeover consent. The unowned branch runs only for ownership
none, and ownership is re-read after the final probe.
- Projection: restart safety credits Desktop when the same app's login registration is verified. Otherwise it is at risk with
recommendedCommand: null and a plain-language recommendedAction. ocx status / doctor share one selector. A live verdict from a runtime that predates this field is replaced by the local reading only when that reading carries matching unowned supervision for the same pids (startupSource: "local-supervision-override"). ocx resolve --json gains an additive supervisor field, which the Rust shell's serde ignores. The status validator now also accepts protection: "desktop" (previously rejected, a latent bug for owned installs too).
- GUI: service/shim install buttons are disabled and service commands hidden while Desktop runs the proxy, with a new localized hint in all 11 locales.
Command guards (service install/update/stop wording) follow in a stacked PR. The plan, audit record and contract are in devlog/_plan/261009_L1-desktop-cli/.

Verification
bun test on the 9 focused files (desktop-startup macOS/Linux, startup-health, autostart-health, status startup/JSON, resolve, GUI startup-health-ui, doctor) with an isolated OPENCODEX_HOME: 332 pass, 0 fail. One existing test (status --json on malformed config) was filtered locally because it probes the default port 10100 where the user's live Desktop proxy runs; CI runs it.
bun run typecheck, bun run lint:gui, GUI tsc -p tsconfig.app.json, bun run build:gui, bun scripts/file-size-ratchet.ts, bun run structure:check, bun run privacy:scan, docs-site build (569 pages, internal links checked): all pass.
- Read-only live check on the reporting Mac against the running 2.81.0 Desktop sidecar:
status --json → startupSource: local-supervision-override, startup.desktop.supervisor = {36806, 36826}, recommendedCommand: null; resolve --json → supervisor.kind: desktop with matching pids.
- Full
bun run test was not run locally (lane instruction: minimal local tests, several worktrees running in parallel); the full suite and Windows/Linux shards are left to CI.
- Independent gpt-6.1-sol code review: 3 rounds (GO-WITH-FIXES ×2 → PASS); every finding fixed with a failing-first regression test.
Checklist
- Scope stays focused and avoids unrelated cleanup.
- Docs or release notes were updated when needed.
- Security-sensitive changes were reviewed for secrets, auth, and unsafe defaults.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
chatgpt-codex-connector[bot] reacted with thumbs up emoji
…ep custom gateway guidance first
Codex Review Summary
This comment shows the latest Codex review activity on this pull request.
| Review |
Status |
Commit |
Review trigger |
| 📝 Code Review |
✅ Completed 2026-10-09T02:18:18.308568Z |
1718fca |
PR opened |
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review" or "@codex security review".
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Warning
Review limit reached
You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.
Next included review available in 14 minutes.
Check out review usage here.
View limit details
Limit details: You’ve used all 10 included reviews currently available.
Learn how review limits work.
Review configuration:
⚙️ Run configuration
- Configuration used: Repository: lidge-jun/opencodex/.coderabbit.yaml
- Review profile: ASSERTIVE
- Plan: Advanced
- Run ID:
ba3d0989-d949-41db-9e92-c0cfab71fd44
📥 Commits
Reviewing files that changed from the base of the PR and between fd20320 and 1718fca.
📒 Files selected for processing (46)
devlog/_plan/261009_L1-desktop-cli/000_plan.md
devlog/_plan/261009_L1-desktop-cli/001_evidence.md
devlog/_plan/261009_L1-desktop-cli/002_consultation.md
devlog/_plan/261009_L1-desktop-cli/003_contract_index.md
devlog/_plan/261009_L1-desktop-cli/010_supervision_evidence_projection.md
devlog/_plan/261009_L1-desktop-cli/011_wp2_execution_packets.md
devlog/_plan/261009_L1-desktop-cli/020_command_guards.md
devlog/_plan/261009_L1-desktop-cli/030_launcher_bun_fallback.md
devlog/_plan/261009_L1-desktop-cli/040_path_cli_decision_closeout.md
docs-site/src/content/docs/guides/desktop-app.md
docs-site/src/content/docs/ko/guides/desktop-app.md
gui/src/i18n/de.ts
gui/src/i18n/en.ts
gui/src/i18n/fr.ts
gui/src/i18n/ja.ts
gui/src/i18n/ko.ts
gui/src/i18n/pt.ts
gui/src/i18n/ru.ts
gui/src/i18n/tr.ts
gui/src/i18n/vi.ts
gui/src/i18n/zh-TW.ts
gui/src/i18n/zh.ts
gui/src/pages/startup-sections.tsx
gui/src/pages/startup-shared.ts
gui/src/startup-health-ui.ts
src/cli/doctor.ts
src/cli/index.ts
src/cli/resolve.ts
src/cli/status.ts
src/codex/autostart-health.ts
src/server/startup-health-cache.ts
src/service/desktop-startup.ts
src/service/desktop-supervision.d.mts
src/service/desktop-supervision.mjs
structure/desktop-shell.md
structure/ops/service-and-sidecars.md
structure/runtime.md
tests/cli/cli-resolve.test.ts
tests/cli/cli-status-json.test.ts
tests/cli/cli-status-startup-health.test.ts
tests/codex-integration/doctor.test.ts
tests/gui/startup-health-ui.test.ts
tests/service/autostart-health.test.ts
tests/service/service-desktop-startup-health.test.ts
tests/service/service-desktop-startup-linux.test.ts
tests/service/service-desktop-startup.test.ts
- Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share
Comment @coderabbitai help to get the list of available commands.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
✅ Deterministic PR hygiene checks passed.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Oct 9, 2026
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Oct 9, 2026
lidge-jun
added a commit
that referenced
this pull request
Oct 10, 2026
…#6855)
* docs(devlog): record the cross-OS probe of the desktop-owned CLI path
Plan, per-host execution notes and outcomes for probing #6802, #6807, #6809, #6812, #6816 and #6818 on Ubuntu 24.04 and Windows 11. Follow-ups: #6851, #6852, #6853, #6854.
* docs(devlog): tighten evidence citations and the F1 hypothesis
* docs(devlog): qualify unretained evidence in the probe outcome
* docs(devlog): record exact-head CI for the probe follow-ups
* docs(devlog): close the cross-OS probe unit and fold review fixes
* docs(devlog): align the P2 escape note and guard the probe cleanup paths
Reviewers
Ingwannu
Awaiting requested review from Ingwannu
Ingwannu is a code owner
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Labels
bug
Something isn't working
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|