Fix Windows npm install regression from dist-tag packaging change#11768
Open
etraut-openai wants to merge 1 commit intomainfrom
Open
Fix Windows npm install regression from dist-tag packaging change#11768etraut-openai wants to merge 1 commit intomainfrom
etraut-openai wants to merge 1 commit intomainfrom
Conversation
The recent packaging migration in #11339 switched platform artifacts to be published as `@openai/codex` with platform-specific versions and wired the meta package via npm alias optional dependencies (for example `@openai/codex-win32-x64 -> npm:@openai/codex@0.101.0-win32-x64`). This caused runtime failures on Windows where `codex` reports: `Missing optional dependency @openai/codex-win32-x64`. ### What changed - Updated `codex-cli/scripts/build_npm_package.py` to publish platform artifacts under their concrete package names: - `@openai/codex-win32-x64` - `@openai/codex-win32-arm64` - `@openai/codex-linux-x64` - `@openai/codex-linux-arm64` - `@openai/codex-darwin-x64` - `@openai/codex-darwin-arm64` - Updated meta package `optionalDependencies` to use plain version references (e.g. `0.101.0-win32-x64`) instead of npm alias syntax to `@openai/codex`. - Updated `codex-cli/scripts/README.md` to reflect that platform-native artifacts are separate optional dependency packages. ### Why `bin/codex.js` resolves platform packages by name (`@openai/codex-win32-x64`, etc). Publishing platform tarballs under `@openai/codex` introduces alias indirection that can fail to materialize these package names at install time, especially on Windows. Publishing under the concrete names restores direct name alignment and reliable resolution.
Collaborator
Author
|
@codex review |
Contributor
|
Codex Review: Didn't find any major issues. Swish! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
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.
The recent packaging migration in #11339 switched platform artifacts to be published as
@openai/codexwith platform-specific versions and wired the meta package via npm alias optional dependencies (for example@openai/codex-win32-x64 -> npm:@openai/codex@0.101.0-win32-x64).This caused runtime failures on Windows where
codexreports:Missing optional dependency @openai/codex-win32-x64.What changed
codex-cli/scripts/build_npm_package.pyto publish platform artifacts under their concrete package names:@openai/codex-win32-x64@openai/codex-win32-arm64@openai/codex-linux-x64@openai/codex-linux-arm64@openai/codex-darwin-x64@openai/codex-darwin-arm64optionalDependenciesto use plain version references (e.g.0.101.0-win32-x64) instead of npm alias syntax to@openai/codex.codex-cli/scripts/README.mdto reflect that platform-native artifacts are separate optional dependency packages.Why
bin/codex.jsresolves platform packages by name (@openai/codex-win32-x64, etc). Publishing platform tarballs under@openai/codexintroduces alias indirection that can fail to materialize these package names at install time, especially on Windows. Publishing under the concrete names restores direct name alignment and reliable resolution.Addresses #11744