Skip to content

chore(release): @commonlyai/cli 0.1.10 — seven source commits shipped to nobody - #1017

Merged
lilyshen0722 merged 2 commits into
mainfrom
chore/cli-0.1.10-and-version-guard
Aug 19, 2026
Merged

lilyshen0722 merged 2 commits into
mainfrom
chore/cli-0.1.10-and-version-guard

Conversation

@lilyshen0722

Copy link
Copy Markdown
Contributor

npm 0.1.9 and main 0.1.9 are different code

Same defect as #979, one package over. Seven source commits have landed since the last version bump, four of them real fixes:

#995 a quota stall was classified as a runtime blip and probed every 5 seconds
#973 a directly-addressed seat can answer past the cascade cap
#1002 a seat log recorded four failures and not one time
#1006 timestamps on log lines
#961 pin an agent's model in the environment spec
#1000, #1005 comment-only

Anyone who installs the CLI today gets none of them. Our own seats have them only because their CLI is npm-linked into a worktree that was pulled by hand — which also means the fleet's behaviour and the published artifact have silently diverged.

#995 is the one I'd care about most: without it, "You've hit your session limit" classifies as a generic runtime blip and the seat retries every 5s against a provider that will not answer for hours, instead of opening the circuit at the 15-minute ceiling. That ran all of last night.

How this keeps happening

A published version is the only check available from outside the repo. Ship source without bumping it and that check silently passes while the artifact and the repo disagree — and there is no way to tell from the outside, which is exactly how #979 survived for months.

Verifying by version is what fails. Verifying by content is what works:

npm view @commonlyai/cli version                    # says 0.1.9
npm pack @commonlyai/cli && tar xzf commonlyai-cli-0.1.9.tgz
grep -c "session limit" package/src/lib/spawn-retry.js   # 0 — #995 is NOT in it

The guard, and why it is not in this PR

I wrote .github/workflows/package-version-guard.yml — fails a PR when cli/src/** or commonly-mcp/src/** changes without a version bump, exempting docs and tests. Validated before proposing: YAML parses, bash -n clean, and dry-run against real history shows it would have caught all 7 of the commits above.

I could not push it. Neither account carries the workflow scope (lilyshen0722: repo, gist, read:org, admin:public_key; samxu01: repo, gist, read:org), and the attempt fails as a bare HTTP 404 that reads like a missing file. The global instructions claimed samxu01 held a workflow-scoped token; that has been corrected.

To land it: gh auth refresh -h github.com -s workflow, then it is a one-call push. Alternatively I can convert it to scripts/verify-package-versions.js + a verify:package-versions npm script — matching the existing verify:moltbot-tools pattern — leaving only a two-line run: step in tests.yml for someone with the scope.

After merge

cd cli && npm publish

# then verify the ARTIFACT, not the version
npm view @commonlyai/cli version                          # expect 0.1.10
cd /tmp && npm pack @commonlyai/cli --silent && tar xzf commonlyai-cli-0.1.10.tgz
grep -c "session limit" package/src/lib/spawn-retry.js    # expect 2
grep -c "addressedGrace" package/src/lib/enforcement.js   # expect >= 1

If those greps return 0, the publish went out of a stale tree and the version is lying again.

npm 0.1.9 and main 0.1.9 are DIFFERENT CODE. Seven source commits have landed
since the last bump, four of them real fixes:

  #995   a quota stall was classified as a runtime blip and probed every 5s
  #973   a directly-addressed seat can answer past the cascade cap
  #1002  a seat log recorded four failures and not one time
  #1006  stamp the line that dates the restart
  #961   pin an agent's model in the environment spec

Anyone who installs the CLI today gets none of them. Our own seats have them
only because their CLI is npm-linked into a worktree that was pulled by hand.

Same defect as #979 one package over: a version that maps to two different
artifacts defeats the only check available from outside the repo.
The published version is the only check available from OUTSIDE this repo. Ship
source without bumping it and that check silently passes while the artifact and
the repo disagree.

Twice now:
  #979   @commonlyai/mcp — npm 0.3.0 and main 0.3.0 were different code; the
         PR-tool removal reached the repo and reached zero seats. Found months
         late, by unpacking the tarball.
  #1017  @commonlyai/cli — npm 0.1.9 and main 0.1.9 were different code, seven
         source commits deep, including #995 (a quota stall classified as a
         runtime blip and probed every 5s). Found the same day, by hand, only
         because someone thought to check content rather than version.

Guards cli/src and commonly-mcp/src. Docs and tests are exempt — they do not
require a release.

Verified before landing: YAML parses, bash -n clean, and the comparison was
dry-run against real history — 7 commits touched cli/src since its last bump,
every one of which this would have failed.
@lilyshen0722
lilyshen0722 merged commit 2836b89 into main Aug 19, 2026
12 checks passed
@lilyshen0722
lilyshen0722 deleted the chore/cli-0.1.10-and-version-guard branch August 19, 2026 02:21
lilyshen0722 added a commit that referenced this pull request Sep 2, 2026
TASK-100, two of its three parts. The third (strict: true, so a PR's
checks must have run against current main) is a branch-protection change
with a measured blast radius and is raised separately.

1. The version guard could not see a PR PAIR.

It compares this PR against its base, so two open PRs bumping the same
package to the same version are both green — neither branch contains the
other's commit. Measured, not assumed: two branches both taking cli
0.1.30 to 0.1.31 while touching different files under cli/src merge with
NO conflict, and the result is a single 0.1.31 holding both PRs' source.
git sees one line changed the same way on both sides and has nothing to
report. npm then carries a version mapping to an artifact neither PR
alone produced — the exact defect of #979 and #1017.

Older PR keeps the version, newer picks the next, so one author can
always clear it alone. Only an ADDED version line counts: every stale
branch carries an old package.json and proposes nothing by doing so.

2. Stacked PRs are under-gated, and it reads as a full green.

Every guard here is `branches: [main]`, so none runs on a PR based on
another feature branch. The three open stacked PRs (#1219, #1172, #1132)
carry 4-5 checks each against ~12 on a main-based PR; absent from all
three are the version guard, the stale-base guard and CodeQL. Nothing
counts checks, so a short green looks like a clean one.

The new guard therefore has no branches filter — a check scoped to main
cannot see the PRs it exists to catch.

Both gh calls in the pairs arm fail closed. An unchecked error yields an
empty version list, which reads as "this PR bumps nothing" and passes:
the guard at its most reassuring exactly when blind.

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
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