Skip to content

Commit abaeda3

Browse files
committed
feat: Update @openai/codex dependency to latest and adjust related documentation
1 parent 4d2b76e commit abaeda3

9 files changed

Lines changed: 16 additions & 21 deletions

File tree

‎assets/crewcoder-logo.png‎

-266 KB
Loading

‎crewcoder-agent/AGENTS.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ CrewCoder should become a best-in-class coding agent with:
2020

2121
## CLI aliases
2222

23+
The `@openai/codex` dependency uses npm's `latest` tag so new CrewCoder installations receive the current stable Codex app-server. Keep `scripts/release.cjs` from replacing that tag with an exact version. Existing installations update only when their package manager installs again.
24+
2325
The agent package maps `crewcoder`, `crew`, and `crewcoder-agent` to the same CLI entrypoint. Keep `crew` behavior identical to `crewcoder`, including no-argument TUI launch and all argument-bearing backend commands. Never restore the `cc` alias because it shadows the standard Unix C compiler command.
2426

2527
`crewcoder update` and its `upgrade` alias update only the public `crewcoder` umbrella through npm's stable `latest` tag. Preserve the current/proposed version preview, interactive arrow-key Yes/No confirmation, `--yes` non-interactive path, and exact up-to-date message. Never update the scoped runtime packages independently from this command.

‎crewcoder-agent/README.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,8 @@ crewcoder upgrade
8989
crewcoder update --yes
9090
```
9191

92+
New installations resolve the current npm `@openai/codex@latest` app-server. Existing installations keep their installed Codex version until npm updates them.
93+
9294
The scoped agent and TUI packages can still be installed separately for development or custom packaging.
9395

9496
## Providers

‎crewcoder-agent/docs/CODEX_TRANSPORT.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ reported as ready.
2121

2222
For a new CrewCoder session, the provider:
2323

24-
1. Starts `codex app-server --stdio` from the pinned `@openai/codex` package.
24+
1. Starts `codex app-server --stdio` from the installed `@openai/codex` package. New installations resolve npm's `latest` tag; existing installations keep their installed version until updated.
2525
2. Performs the JSON-RPC initialize handshake with experimental dynamic-tool support.
2626
3. Calls `thread/start` and sends the current CrewCoder conversation context for the first turn.
2727
4. Persists an encoded native thread ID in `providerSessionIds.codex`.

‎crewcoder-agent/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
"dependencies": {
5959
"@agentclientprotocol/sdk": "^1.3.0",
6060
"@anthropic-ai/claude-agent-sdk": "0.3.282",
61-
"@openai/codex": "0.159.1",
61+
"@openai/codex": "latest",
6262
"commander": "^12.1.0",
6363
"fs-extra": "^11.2.0",
6464
"picocolors": "^1.0.1",

‎docs/RELEASING.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Create a coordinated release from a clean branch with one command:
66
npm run release -- 0.7.0
77
```
88

9-
The command checks npm's `latest` dist-tag for `@openai/codex` and pins that exact version for the agent package. It then updates the umbrella, agent, browser client, and SDK package versions as one coordinated release group. It preserves the TUI package version and the umbrella package's existing exact TUI dependency. It also updates the release group's exact internal dependencies, runtime version constants, generated client and SDK version API baselines, and `package-lock.json`; runs the SDK release checks; creates a `chore(release): v0.7.0` commit and annotated `v0.7.0` tag; then atomically pushes the current branch and tag to its configured remote.
9+
The command keeps the agent package's `@openai/codex` dependency on npm's `latest` tag, so each new user installation resolves the current stable Codex release. It updates the umbrella, agent, browser client, and SDK package versions as one coordinated release group. It preserves the TUI package version and the umbrella package's existing exact TUI dependency. It also updates the release group's exact internal dependencies, runtime version constants, generated client and SDK version API baselines, and `package-lock.json`; runs the SDK release checks; creates a `chore(release): v0.7.0` commit and annotated `v0.7.0` tag; then atomically pushes the current branch and tag to its configured remote.
1010

1111
Only `crewcoder-client/api/version.d.ts` and `crewcoder-sdk/api/version.d.ts` may change during the automatic API baseline refresh. Any other public declaration change stops the release for explicit review.
1212

@@ -24,7 +24,7 @@ The release stops before changing files when:
2424

2525
It also stops before committing if version metadata, lockfile generation, or release checks fail. A failure after metadata generation intentionally leaves those changes visible for inspection. A failed atomic push leaves the local release commit and tag intact; fix the remote issue and retry the exact `git push --atomic` command printed by the release script.
2626

27-
Preview validation without changing files or contacting the Git remote. The dry run still queries npm for the current Codex version:
27+
Preview validation without changing files or contacting the Git remote:
2828

2929
```sh
3030
npm run release -- 0.7.0 --dry-run

‎package-lock.json‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎scripts/release.cjs‎

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,7 @@ function replaceVersionConstant(filePath, constantName, version) {
6868
fs.writeFileSync(filePath, source.replace(pattern, `$1${version}$2`));
6969
}
7070

71-
function updateReleaseMetadata(repositoryRoot, version, codexVersion) {
72-
stableVersionParts(codexVersion);
71+
function updateReleaseMetadata(repositoryRoot, version) {
7372
const manifests = new Map();
7473
for (const relativePath of releasePackageFiles) {
7574
const filePath = path.join(repositoryRoot, relativePath);
@@ -80,7 +79,7 @@ function updateReleaseMetadata(repositoryRoot, version, codexVersion) {
8079
}
8180

8281
manifests.get("package.json").manifest.dependencies["@onpoint-dev-tools/crewcoder-agent"] = version;
83-
manifests.get("crewcoder-agent/package.json").manifest.dependencies["@openai/codex"] = codexVersion;
82+
manifests.get("crewcoder-agent/package.json").manifest.dependencies["@openai/codex"] = "latest";
8483
manifests.get("crewcoder-sdk/package.json").manifest.dependencies["@onpoint-dev-tools/crewcoder-agent"] = version;
8584
manifests.get("crewcoder-sdk/package.json").manifest.dependencies["@onpoint-dev-tools/crewcoder-client"] = version;
8685

@@ -90,12 +89,6 @@ function updateReleaseMetadata(repositoryRoot, version, codexVersion) {
9089
replaceVersionConstant(path.join(repositoryRoot, "crewcoder-sdk/src/version.ts"), "CREWCODER_SDK_VERSION", version);
9190
}
9291

93-
function resolveLatestCodexVersion() {
94-
const version = run("npm", ["view", "@openai/codex", "dist-tags.latest"], { capture: true });
95-
stableVersionParts(version);
96-
return version;
97-
}
98-
9992
function resolveRemote(branch) {
10093
const configured = spawnSync("git", ["config", "--get", `branch.${branch}.remote`], { cwd: root, encoding: "utf8" });
10194
const remote = configured.status === 0 ? configured.stdout.trim() : "origin";
@@ -119,8 +112,6 @@ function main(args) {
119112
if (run("git", ["status", "--porcelain", "--untracked-files=all"], { capture: true })) {
120113
fail("The worktree must be completely clean so release checks match the tagged commit.");
121114
}
122-
const codexVersion = resolveLatestCodexVersion();
123-
124115
const branch = run("git", ["branch", "--show-current"], { capture: true });
125116
if (!branch) fail("Releases cannot be created from a detached HEAD.");
126117
const remote = resolveRemote(branch);
@@ -143,7 +134,7 @@ function main(args) {
143134

144135
console.log(`Preparing ${tag} from ${branch} for ${remote}.`);
145136
console.log(`Packages: ${currentVersions.join(", ")} -> ${version}`);
146-
console.log(`Codex runtime: @openai/codex@${codexVersion}`);
137+
console.log("Codex runtime: @openai/codex@latest (resolved when installed)");
147138
if (dryRun) {
148139
console.log("Dry run passed; no files, commits, tags, or Git remotes were changed.");
149140
return;
@@ -155,7 +146,7 @@ function main(args) {
155146
run("git", ["fetch", "--quiet", remote, `refs/heads/${branch}`]);
156147
run("git", ["merge-base", "--is-ancestor", "FETCH_HEAD", "HEAD"], { capture: true });
157148

158-
updateReleaseMetadata(root, version, codexVersion);
149+
updateReleaseMetadata(root, version);
159150
run("npm", ["install", "--package-lock-only", "--ignore-scripts", "--no-audit", "--no-fund"]);
160151
run("npm", ["run", "api:update", "-w", "@onpoint-dev-tools/crewcoder-client"]);
161152
run("npm", ["run", "api:update", "-w", "@onpoint-dev-tools/crewcoder-sdk"]);
@@ -198,4 +189,4 @@ if (require.main === module) {
198189
}
199190
}
200191

201-
module.exports = { compareVersions, releaseFiles, resolveLatestCodexVersion, stableVersionParts, updateReleaseMetadata };
192+
module.exports = { compareVersions, releaseFiles, stableVersionParts, updateReleaseMetadata };

‎test/release.test.js‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ describe("release automation", () => {
5252
fs.writeFileSync(filePath, source);
5353
}
5454

55-
updateReleaseMetadata(repositoryRoot, "0.2.3", "0.155.1");
55+
updateReleaseMetadata(repositoryRoot, "0.2.3");
5656

5757
for (const relativePath of Object.keys(manifests).filter((relativePath) => relativePath !== "crewcoder-tui/package.json")) {
5858
expect(JSON.parse(fs.readFileSync(path.join(repositoryRoot, relativePath), "utf8")).version).toBe("0.2.3");
@@ -69,7 +69,7 @@ describe("release automation", () => {
6969
"@onpoint-dev-tools/crewcoder-client": "0.2.3"
7070
});
7171
const agentManifest = JSON.parse(fs.readFileSync(path.join(repositoryRoot, "crewcoder-agent/package.json"), "utf8"));
72-
expect(agentManifest.dependencies["@openai/codex"]).toBe("0.155.1");
72+
expect(agentManifest.dependencies["@openai/codex"]).toBe("latest");
7373
for (const relativePath of Object.keys(constants)) {
7474
expect(fs.readFileSync(path.join(repositoryRoot, relativePath), "utf8")).toContain('"0.2.3"');
7575
}

0 commit comments

Comments
 (0)