Skip to content

Linux x64 optional tarball 404 — 0.125.0 install leaves CLI broken (“Missing optional dependency @openai/codex-linux-x64”) #19419

Closed

Description

@sarath-shekkizhar

What version of Codex CLI is running?

0.125.0

What subscription do you have?

API

Which model were you using?

No response

What platform is your computer?

Linux (x86_64)

What terminal emulator and version are you using (if applicable)?

No response

What issue are you seeing?

codex throws:

Error: Missing optional dependency @openai/codex-linux-x64. Reinstall Codex: npm install -g @openai/codex@latest

After npm install -g @openai/codex@latest, the @openai/codex tree has no usable node_modules/@openai/codex-linux-x64 (or the optional install never completes).

Root cause (suspected)

npm view @openai/[email protected] reports a valid dist.tarball, but fetching that tarball returns HTTP 404, so npm cannot install the optional dependency. Example URL from metadata:

https://registry.npmjs.org/@openai/codex/-/codex-0.125.0-linux-x64.tgz

For comparison, the previous Linux x64 artifact (e.g. codex-0.124.0-linux-x64.tgz) returns 200, and npm install -g @openai/[email protected] works: node_modules/@openai/codex-linux-x64/vendor is present and codex -V succeeds.

Workaround

Pin until the 0.125.0-linux-x64 tarball is available on the registry:

npm install -g @openai/[email protected]

Suggestions

  • Fix or republish the 0.125.0-linux-x64 (and any other platform) tarball so it matches npm metadata.
  • Consider surfacing failed optional dependency installs more clearly during npm install -g (e.g. document checking npm ls -g @openai/codex / tarball URL), since the current runtime error is easy to misread as a local install problem.

What steps can reproduce the bug?

Environment

  • OS: Linux (x86_64)
  • Node: v24.x (also reproducible with other supported Node versions)
  • Install: npm install -g @openai/codex@latest (resolves to @openai/[email protected])

Steps to reproduce

  1. npm install -g @openai/codex@latest
  2. codex

What is the expected behavior?

Expected

The CLI starts; optional platform package @openai/codex-linux-x64 (aliased to npm:@openai/[email protected]) is present under the package’s node_modules, matching optionalDependencies in package.json.

Additional information

No response

Activity

  1. added
    bug
    on Apr 24, 2026
  2. added
    CLI
    connectivity
    on Apr 24, 2026
  3. github-actions commented on Apr 24, 2026

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  4. etraut-openai commented on Apr 24, 2026

    @etraut-openai
    Contributor

    This is probably because of a timing issue related to uploading to npm. Please try again in a few minutes.

  5. andrewklingelhofer commented on Apr 25, 2026

    @andrewklingelhofer

    Having a similar issue with brew on Mac

  6. FelixWardUS commented on Apr 26, 2026

    @FelixWardUS

    I ran into this class of issue enough times that I made a tiny pre-check tool for it:

    https://github.com/FelixWardUS/codex-npm-check

    For this case, it checks whether both the main package and the Linux x64 variant have npm metadata and a reachable tarball before installing:

    npm install -g codex-npm-check
    cnc

    It is only meant to catch npm publishing/registry problems like missing platform builds or tarball 404s. It will not catch runtime bugs after the package installs.

  7. etraut-openai commented on Apr 26, 2026

    @etraut-openai
    Contributor

    This will be fixed in the next release, thanks to this PR. Actually, it will be completely fixed one release after next because part of the fix is in the client code. The next CLI release will include the fix so it can avoid this problem on the following update.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLIbugconnectivity

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions