fix(codex-shim): pass non-remote subcommands through - #590
Open
hyamakawa7 wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Prevent the Codex monitor shim from routing non-remote CLI subcommands through the app-server bridge.
When monitor delivery is enabled, commands such as:
codex plugin marketplace add owner/repositorywere incorrectly routed through the bridge. The bridge injected
--remote, which Codex rejects for non-interactive subcommands:No existing issue or pull request covering this exact failure was found.
Root cause
codex-shim.shuses an allowlist for subcommands that should invoke the real Codex CLI directly. Several non-remote subcommands and aliases were missing, so they fell through to the monitored TUI path.Changes
plugin,mcp-server,remote-control,update,doctor,cloud,exec-server,features, and thee/aaliases.fork,archive,delete, andunarchive) on the monitor path.Verification
tests/test_codex_shim.bats: 18/18 passed.resolve_node: finds the newest version-manager node when PATH lacks node: this Ubuntu environment resolved/usr/bin/nodeinstead of the test's fake NVM node. The failing resolver and its test are unchanged by this PR.Environment:
1c7efbcWorkaround for existing installations
Until this fix is installed, users can bypass the shim for a single command:
AGMSG_CODEX_SHIM_DISABLE=1 codex plugin marketplace add owner/repository