Skip to content

fix: install codex-code-mode-host alongside codex (code review) - #32

Merged
thecodeassassin merged 1 commit into
mainfrom
fix/codex-code-mode-host
Jul 9, 2026
Merged

fix: install codex-code-mode-host alongside codex (code review)#32
thecodeassassin merged 1 commit into
mainfrom
fix/codex-code-mode-host

Conversation

@thecodeassassin

Copy link
Copy Markdown
Contributor

Recent Codex versions spawn a sibling binary codex-code-mode-host for the new code-review / "code mode" feature. It ships as a separate release asset, but ExitBox only downloaded the main codex tarball — so code review failed with:

Unable to review the changes because the repository inspection tool failed to start (codex-code-mode-host is missing).

Fix

  • CodeModeHostBinaryName() returns the codex-code-mode-host-<arch>-unknown-linux-musl.tar.gz asset.
  • PrepareBuild now downloads it too, computes its SHA-256, and passes it as CODEX_CODE_MODE_HOST_CHECKSUM.
  • GetDockerfileInstall COPYs + checksum-verifies + extracts it to $HOME/.local/bin/codex-code-mode-host, next to the codex binary (verified the tarball extracts to codex-code-mode-host-<arch>-unknown-linux-musl, same convention as codex).

Codex looks for the host binary beside itself / on PATH, and $HOME/.local/bin is both — so code review works after a rebuild.

Tests

codex_test.go: assert CodeModeHostBinaryName() per arch, and that GetDockerfileInstall installs codex-code-mode-host + verifies its checksum. go build, go test ./..., go vet, golangci-lint green.

Caveat: pinning agents.codex.version to a very old release (before the code-mode-host asset existed) will now fail the download; use latest (the default). Needs an image rebuild (exitbox run codex --update).

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Merging this branch will not change overall coverage

Impacted Packages Coverage Δ 🤖
github.com/Cloud-Exit/ExitBox/internal/agents/codex 0.00% (ø)

Coverage by file

Changed files (no unit tests)

Changed File Coverage Δ Total Covered Missed 🤖
github.com/Cloud-Exit/ExitBox/internal/agents/codex/codex.go 0.00% (ø) 0 0 0
github.com/Cloud-Exit/ExitBox/internal/agents/codex/docker.go 0.00% (ø) 0 0 0

Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code.

Changed unit test files

  • github.com/Cloud-Exit/ExitBox/internal/agents/codex/codex_test.go

@thecodeassassin
thecodeassassin merged commit 9b5e396 into main Jul 9, 2026
7 checks passed
@thecodeassassin
thecodeassassin deleted the fix/codex-code-mode-host branch July 9, 2026 21:56
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