Skip to content

fix(libs): align the generated version constants with the manifests - #1111

Merged
blove merged 1 commit into
mainfrom
blove/fix-stale-package-version
Sep 19, 2026
Merged

blove merged 1 commit into
mainfrom
blove/fix-stale-package-version

Conversation

@blove

@blove blove commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

The four committed package-version.ts files read 0.0.66 while their package.json files read 0.2.0. That constant feeds runtime telemetry, so a source checkout reported a version three releases old.

Why they drift

The release flow never commits them, and cannot easily. nx release version runs its prebuild before rewriting the manifests, so a regeneration during a release embeds the previous version. docs/RELEASE.md warns about exactly this. Published artifacts were never affected, because the tag-driven publish rebuilds from the versioned sources; only the checked-in copies went stale.

What this does

Regenerates all four from the current manifests using the same assemble-package target that produces them. No hand-editing. The tracked .install-collector outputs regenerated byte-identical, so nothing else moved.

A side effect worth having: a library test run no longer leaves these four files dirty. That churn had been mistaken for a spurious 0.1.0 bump and reverted by hand repeatedly, including by me earlier today. With the committed values correct, the regeneration is a no-op.

Verification

nx run-many -t test,build across chat, ag-ui, langgraph and render passes, and the working tree after that run contains only the four intended files.

Follow-up not done here

Nothing prevents this drifting again. The obvious guard, a unit test comparing the constant to package.json, would be vacuous: the build regenerates the file and runs before the test, so it would always compare a freshly written value against its own source and pass. A real guard has to check the committed file, for example a CI step running the prepare-install target and then git diff --exit-code. That is a workflow change and deliberately out of scope here rather than shipped as a test that looks like protection and is not.

🤖 Generated with Claude Code

The four committed package-version.ts files read 0.0.66 while their
package.json files read 0.2.0. The constant feeds runtime telemetry, so a
source checkout reported a version three releases old.

They drift because the release flow never commits them: nx release version
runs its prebuild BEFORE rewriting the manifests, so a regeneration during
a release embeds the previous version. Published artifacts are unaffected,
since the tag-driven publish rebuilds from the versioned sources.

Regenerated from the current manifests with the same assemble-package
target that produces them. A side effect worth having: a library test run
no longer leaves these four files dirty, which had been mistaken for
spurious churn and reverted by hand.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated approval: this PR received an intelligent (AI) code review. See the review comments on this PR.

@github-actions

github-actions Bot commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Claude finished @blove's task in 0s —— View job


I'll analyze this and get back to you.

@vercel

vercel Bot commented Sep 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
threadplane Ready Ready Preview Sep 18, 2026 9:58pm UTC

Request Review

@blove
blove merged commit 23120d1 into main Sep 19, 2026
147 of 149 checks passed
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