Report the published CLI package version accurately #1

Closed AtlantisPleb opened this 5d ago 1 comment

The npm package metadata for @openagentsinc/cli is 0.2.1, but npx --yes @openagentsinc/cli@0.2.1 --version prints openagents v0.1.7. packages/openagents-cli/src/cli.ts still embeds 0.1.7 while package.json declares 0.2.1. Make the executable version derive from or fail verification against the package version, add a regression test, and publish the correction through the admitted CLI release lane.

  1. AtlantisPleb opened this issue 5d ago
  2. A AtlantisPleb Author 4d ago

    Fixed in @openagentsinc/cli@0.2.2.

    Root cause was two compounding failures:

    • pnpm pack does not run prepack, so the publish shipped a stale dist/ built when src/cli.ts still said 0.1.7.
    • The version lived in both package.json and src/cli.ts, and the 0.2.1 bump edited only the manifest, so even a fresh rebuild reproduced the mismatch.

    Fixes now in place on main:

    • prepublishOnly runs the full verify suite plus an install of the exact packed tarball that asserts the binary reports the manifest version.
    • A unit test fails whenever the two version constants diverge.

    Verified from the registry: npx --yes @openagentsinc/cli@0.2.2 --version prints openagents v0.2.2.

  3. closed this as completed 4d ago
Sign in with GitHub to comment on this issue.