GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(cli): diagnose Orca Codex home mismatch by Ingwannu · Pull Request #503 · lidge-jun/opencodex

Conversation

@Ingwannu

@Ingwannu Ingwannu commented Jul 26, 2026 •
edited by coderabbitai Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Owner

Summary

  • preserve explicit CODEX_HOME semantics while detecting the high-confidence Windows Orca runtime-home mismatch
  • surface the effective/app homes and actionable service-migration warning in ocx doctor and human/JSON ocx status
  • redact OS usernames from every new displayed/JSON/logged Codex-home path
  • qualify sync and restore back output with the exact redacted target home
  • document the behavior in English, Korean, Japanese, Chinese, and Russian CLI/Codex integration guides

Validation

  • bun test tests/doctor.test.ts tests/cli-status-json.test.ts tests/codex-sync-api.test.ts tests/cli-restore-back.test.ts (39 passed)
  • bun run typecheck
  • docs-site production build (131 pages) passed

Closes #497

Summary by CodeRabbit

  • New Features

    • Added Codex home targeting diagnostics to ocx status, ocx doctor, sync, and restore output.
    • Windows Orca/App home mismatches now emit warnings with redacted effective/app homes and remediation action guidance.
    • ocx status --json now includes a codexHome object with effectiveCodexHome, appCodexHome, mismatch, warning, and action.
  • Documentation

    • Updated Codex integration and CLI reference docs (including examples) to describe the new diagnostics and recovery flow.
  • Tests

    • Extended CLI/API and doctor tests to validate the new codexHome fields and Windows mismatch scenarios.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Ingwannu
fix(cli): diagnose Orca Codex home mismatch
cf26fe3
@Ingwannu
Ingwannu requested a review from lidge-jun as a code owner July 26, 2026 13:02
@github-actions github-actions Bot added the bug Something isn't working label Jul 26, 2026
@coderabbitai

coderabbitai Bot commented Jul 26, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

OpenCodex adds Windows Orca Codex-home mismatch detection, exposes it through status and doctor diagnostics, and reports effective Codex targets during sync and restore operations. JSON output, focused tests, and multilingual documentation are updated.

Changes

Codex home diagnostics

Layer / File(s) Summary
Diagnostic contract and detection
src/codex/home.ts, tests/doctor.test.ts
Adds OrcaCodexHomeDiagnostic, detects Windows Orca runtime-home mismatches against the app .codex home, and tests mismatch, aligned, and custom-home cases.
Status and doctor reporting
src/cli/status.ts, src/cli/doctor.ts, src/cli/index.ts, tests/cli-status-json.test.ts, docs-site/src/content/docs/{ja,ko,...}/reference/cli.md
Adds codexHome to status JSON and reports effective homes, warnings, and actions in status and doctor output.
Sync and restore target messaging
src/codex/sync.ts, src/cli/index.ts, tests/codex-sync-api.test.ts, tests/cli-restore-back.test.ts
Logs effective Codex targets during both sync paths and restore-back, with default and mismatch logging assertions.
Policy and CLI documentation
structure/02_config-and-codex-home.md, docs-site/src/content/docs/guides/*, docs-site/src/content/docs/{ja,ko,ru,zh-cn}/guides/*, docs-site/src/content/docs/reference/cli.md, docs-site/src/content/docs/{ja,ko,ru,zh-cn}/reference/cli.md
Documents Windows Orca/App home behavior, redacted diagnostic paths, remediation guidance, and the extended status JSON shape across localized guides and references.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Sequence Diagram(s)

sequenceDiagram
  participant CLI
  participant StatusCollector
  participant HomeDiagnostic
  participant CodexSync
  CLI->>StatusCollector: collectStatus()
  StatusCollector->>HomeDiagnostic: collectOrcaCodexHomeDiagnostic()
  HomeDiagnostic-->>StatusCollector: codexHome diagnostic
  StatusCollector-->>CLI: status JSON and warnings
  CodexSync->>HomeDiagnostic: collectCodexHomeDiagnostic()
  HomeDiagnostic-->>CodexSync: effective home and mismatch guidance
  CodexSync-->>CLI: target home and warning/action output
Loading

Possibly related PRs

  • lidge-jun/opencodex#333: Both changes modify syncModelsToCodex and its external-provider handling.
  • lidge-jun/opencodex#387: Both changes extend the ocx status --json contract and its tests.

Suggested labels: enhancement, documentation

Suggested reviewers: lidge-jun

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 16.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is concise and accurately summarizes the main change: diagnosing the Orca Codex home mismatch in the CLI.
Linked Issues check ✅ Passed The changes satisfy #497 by detecting the Windows Orca/app-home mismatch, redacting paths, warning on migration, and preserving explicit custom homes.
Out of Scope Changes check ✅ Passed The added tests, docs, and CLI/status updates all support the mismatch-detection fix and do not introduce obvious unrelated scope.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch agent/fix-issue-497-orca-home-diagnostic

Comment @coderabbitai help to get the list of available commands.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

coderabbitai[bot]
coderabbitai Bot reviewed Jul 26, 2026
View reviewed changes

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@tests/doctor.test.ts`:
- Around line 81-110: Extend behavioral coverage for rendered Orca mismatch
diagnostics across all affected paths. In tests/doctor.test.ts:81-110, execute
runDoctor with a simulated mismatch and assert the targeting section includes
the warning, action, and effective target. In
tests/cli-status-json.test.ts:79-85, provide the complete mismatch diagnostic
contract; at 127-130, assert deterministic mismatch output rather than only
field types. In tests/cli-restore-back.test.ts:18, replace the source-string
check with executed restore-back output assertions and add equivalent coverage
for both syncModelsToCodex branches, extracting or injecting the diagnostic
formatter as needed.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 2fdcc799-962a-4163-a2a6-49f0ff0c6902

📥 Commits

Reviewing files that changed from the base of the PR and between 911373d and cf26fe3.

📒 Files selected for processing (9)
  • src/cli/doctor.ts
  • src/cli/index.ts
  • src/cli/status.ts
  • src/codex/home.ts
  • src/codex/sync.ts
  • structure/02_config-and-codex-home.md
  • tests/cli-restore-back.test.ts
  • tests/cli-status-json.test.ts
  • tests/doctor.test.ts

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread tests/doctor.test.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

chatgpt-codex-connector[bot]
chatgpt-codex-connector Bot reviewed Jul 26, 2026
View reviewed changes

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cf26fe3b45

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread src/codex/sync.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/cli/index.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/codex/sync.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/codex/home.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

@Ingwannu
fix(cli): harden Orca home diagnostics
071d291
@coderabbitai coderabbitai Bot mentioned this pull request Jul 26, 2026
feat(codex): add opt-in native subagent defaults #498
Merged
3 tasks done
Ingwannu added 2 commits July 26, 2026 13:42
@Ingwannu
Merge remote-tracking branch 'origin/dev' into agent/fix-issue-497-or…
2228fe9
…ca-home-diagnostic
@Ingwannu
Merge remote-tracking branch 'origin/dev' into agent/fix-issue-497-or…
8efe4f1
…ca-home-diagnostic
coderabbitai[bot]
coderabbitai Bot reviewed Jul 26, 2026
View reviewed changes

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs-site/src/content/docs/reference/cli.md`:
- Around line 68-70: Revise the CLI status wording to state that warnings apply
only to the explicit, high-confidence Orca dual-home mismatch detector, not
every Windows Orca/App mismatch. Apply the same narrowed meaning consistently in
docs-site/src/content/docs/reference/cli.md:68-70,
docs-site/src/content/docs/ja/reference/cli.md:65-66,
docs-site/src/content/docs/ko/reference/cli.md:68-69,
docs-site/src/content/docs/ru/reference/cli.md:74-76, and
docs-site/src/content/docs/zh-cn/reference/cli.md:66-67, preserving each
document’s language.

In `@src/codex/home.ts`:
- Around line 202-203: Update the mismatch recovery action in the action
expression to use a Windows-executable command sequence and a shell-safe
symbolic target such as %USERPROFILE%\.codex, while keeping displayed paths
redacted. Replace the mixed POSIX unset/CMD set instructions with explicit CMD
or PowerShell equivalents, preserving the existing uninstall, rerun, and
reinstall steps.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 7162bb2b-3140-4949-b656-ee3a22abf518

📥 Commits

Reviewing files that changed from the base of the PR and between cf26fe3 and 8efe4f1.

📒 Files selected for processing (15)
  • docs-site/src/content/docs/guides/codex-integration.md
  • docs-site/src/content/docs/ja/guides/codex-integration.md
  • docs-site/src/content/docs/ja/reference/cli.md
  • docs-site/src/content/docs/ko/guides/codex-integration.md
  • docs-site/src/content/docs/ko/reference/cli.md
  • docs-site/src/content/docs/reference/cli.md
  • docs-site/src/content/docs/ru/guides/codex-integration.md
  • docs-site/src/content/docs/ru/reference/cli.md
  • docs-site/src/content/docs/zh-cn/guides/codex-integration.md
  • docs-site/src/content/docs/zh-cn/reference/cli.md
  • src/codex/home.ts
  • src/codex/sync.ts
  • structure/02_config-and-codex-home.md
  • tests/codex-sync-api.test.ts
  • tests/doctor.test.ts

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread docs-site/src/content/docs/reference/cli.md Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/codex/home.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

@Ingwannu
fix(cli): make Orca recovery guidance executable
cf7c30a
coderabbitai[bot]
coderabbitai Bot reviewed Jul 26, 2026
View reviewed changes

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/codex/home.ts`:
- Line 203: Update the PowerShell recovery text in the service-remediation
message so Remove-Item and the CODEX_HOME assignment are separated with a valid
PowerShell separator such as a semicolon or distinct commands. Preserve the
existing symbolic $env:USERPROFILE target and the parallel Command Prompt
instructions.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: c800ccc2-40e5-4ccf-a391-184927f3b0ea

📥 Commits

Reviewing files that changed from the base of the PR and between 8efe4f1 and cf7c30a.

📒 Files selected for processing (7)
  • docs-site/src/content/docs/ja/reference/cli.md
  • docs-site/src/content/docs/ko/reference/cli.md
  • docs-site/src/content/docs/reference/cli.md
  • docs-site/src/content/docs/ru/reference/cli.md
  • docs-site/src/content/docs/zh-cn/reference/cli.md
  • src/codex/home.ts
  • tests/doctor.test.ts

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread src/codex/home.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

@Ingwannu
Ingwannu merged commit 94b1437 into dev Jul 26, 2026
14 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@Ingwannu Ingwannu mentioned this pull request Jul 26, 2026
fix(cli): separate PowerShell recovery commands #505
Merged
@Ingwannu ChatGPT Codex Connector

Ingwannu commented Jul 26, 2026

Copy link
Copy Markdown
Owner Author

The final late CodeRabbit finding about the PowerShell separator is valid. PR #505 contains the minimal follow-up against dev: replace the prose and with an executable PowerShell semicolon and regression-test the exact separator. Local focused tests (26) and TypeScript typecheck pass; I will merge it only after its required CI is green.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Ingwannu ChatGPT Codex Connector

Ingwannu commented Jul 26, 2026

Copy link
Copy Markdown
Owner Author

Follow-up PR #505 is now merged into dev (9d1bb146). The PowerShell remediation uses a valid semicolon separator, the focused doctor regression is pinned, and all 12 required CI checks passed across Ubuntu, macOS, and Windows.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Ingwannu Ingwannu mentioned this pull request Jul 26, 2026
ocx injects into $CODEX_HOME (Orca's runtime home on Windows), silently missing the ChatGPT app's ~/.codex while reporting success #497
Closed
@coderabbitai coderabbitai Bot mentioned this pull request Jul 28, 2026
Add Traditional Chinese (zh-TW) localization for GUI, README, and docs #581
Closed
15 tasks done
@lidge-jun
lidge-jun deleted the agent/fix-issue-497-orca-home-diagnostic branch July 29, 2026 04:29
This was referenced Aug 7, 2026
fix(codex): stop reporting every history failure as a Codex DB lock #1202
Merged
fix(subagent): move per-role model fallback into opencodex config (#1190) #1210
Closed
fix(service): align WSL Codex home ownership #1427
Merged
Codex sync did not complete. Fix the reported Codex config issue and retry. #1672
Closed
@coderabbitai coderabbitai Bot mentioned this pull request Aug 15, 2026
feat(storage): inspect Codex diagnostic logs safely - Part 1 #1727
Merged
2 of 3 tasks
agentHits pushed a commit to agentHits/opencodex that referenced this pull request Sep 17, 2026
@Ingwannu
Merge pull request lidge-jun#503 from lidge-jun/agent/fix-issue-497-o…
524e0f4
…rca-home-diagnostic

fix(cli): diagnose Orca Codex home mismatch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@coderabbitai coderabbitai[bot] coderabbitai[bot] left review comments
@chatgpt-codex-connector chatgpt-codex-connector[bot] chatgpt-codex-connector[bot] left review comments
@lidge-jun lidge-jun Awaiting requested review from lidge-jun lidge-jun 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

Projects

None yet

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.

1 participant

@Ingwannu
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.