feat(ci): version the VS Code extension with the rest of Apollon#809
Conversation
Claudia-Anthropica
left a comment
There was a problem hiding this comment.
@FelixTJDietrich The fixed-group config itself behaves as described; I verified changeset status and a temp changeset version simulation produce 5.1.1 across the four packages. I’m requesting changes because the VS Code release job still does not publish the generated changelog text, and a contributor guide still tells people to skip VS Code changesets.
Claudia-Anthropica
left a comment
There was a problem hiding this comment.
@FelixTJDietrich All feedback addressed, nice work.
The extension's manifest has said `1.0.0` at every commit since at least February. Nobody chose it — it is `npm init`'s default, and the Marketplace listing it supposedly describes is at `0.0.17`. Meanwhile the library, the webapp and the server are at `5.1.0`. Put `apollon-vscode` in a Changesets `fixed` group with them. The next Version Packages PR carries it from `1.0.0` straight to `5.1.1`, alongside the other three, and merging that PR is what publishes it — `Release VS Code Extension` already fires on the version change. Nothing is hand-edited; Changesets aligns a group member to the group's highest version. `Version Bump (VS Code extension)` existed only to bump a package Changesets was told to ignore. It is deleted. The trade is worth naming, and the docs now name it: a changeset touching only the extension republishes the library and the standalone images at the new version with identical content. `linked` would avoid that, at the price of the numbers drifting apart. One product number is the point. The extension's CHANGELOG becomes what Changesets writes. Its prose preamble had to go: Changesets inserts each release directly after the first line, so anything below the heading is pushed under every future release. The `0.0.17` migration note moves into the changeset, where it also reaches the GitHub Release body. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Review caught that the migration note this PR moves into a changeset never reaches anyone. `release-vscode-extension.yml` created its GitHub Release with `--generate-notes` and a static body, ignoring `vscode-extension/CHANGELOG.md` entirely — so the curated, per-PR voice that Changesets assembles was written and then discarded. The library and standalone tracks have always fed `extract-changelog.mjs` into `--notes-file`; the extension now does the same, and `npm-publishing.md` stops claiming that every track already did. Full history is fetched for it, because the script recovers each entry's Conventional Commit type from the SHA in the changelog line to group the notes. An empty section falls back to `--generate-notes`, as elsewhere. The contributor guide told authors to skip changesets for VS Code-only work, which the new flow depends on them writing. It also promised the library is never dragged up by a standalone bump — a `fixed` group drags every member, which is what one product number costs. Both corrected. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
6d45a1c to
9ff0482
Compare
|
Rebased onto Re-verified after the rebase rather than assuming, since the merge base moved:
|
Summary
vscode-extension/package.jsonhas said1.0.0at every commit I can trace back to 2026-02-03. Nobody chose it; it isnpm init's default. The Marketplace listing it supposedly describes is at0.0.17, published 2024-11 — so that field has never driven a release. Meanwhile@tumaet/apollon,@tumaet/webappand@tumaet/serverare all at5.1.0.apollon-vscodejoins them in a Changesetsfixedgroup. It carries Apollon's version from now on.What happens next
Nothing, until you merge a Version Packages PR. Then all four move together:
@tumaet/apollon5.1.05.1.1@tumaet/webapp5.1.05.1.1@tumaet/server5.1.05.1.1apollon-vscode1.0.05.1.1No version is hand-edited here, and that is deliberate. Changing
vscode-extension/package.json's version in this PR would fireRelease VS Code Extensionon merge and publish immediately — the premature release #808 exists to prevent. Changesets aligns afixed-group member to the group's highest version on its own, so1.0.0 → 5.1.1happens inside the Version Packages PR, and merging that is the deliberate release.0.0.17 → 5.1.1is monotonic, so the Marketplace accepts it.version-monotonicity.ymlis satisfied for the same reason.The trade, stated plainly
fixedmeans a changeset touching only the extension still bumps and republishes the library and the standalone images, at a new version, with identical content. That is the cost of one product number.The alternative is
linked, which bumps only what changed but lets the numbers drift apart again — which is the thing we're fixing. I've gone withfixedand written the trade intodocs/contributor/deployment/npm-publishing.mdso the next person doesn't rediscover it. Say the word and I'll switch tolinked.Two smaller consequences:
Version Bump (VS Code extension)is deleted. It existed only to hand-bump a package Changesets was told to ignore. Extension work now records apnpm changesetlike everything else.apollon-vscodeis no longer inignore, which was also what kept it away from npm. Nothing publishes it there —release.ymlruns Changesets in version-only mode — but I've written that constraint into the docs rather than leave it implicit. It ships to the Marketplace, never to npm.CHANGELOG
vscode-extension/CHANGELOG.mdis now what Changesets writes, matchinglibrary/CHANGELOG.md. Its prose preamble had to go: Changesets inserts each release directly after the first line, so anything under the heading gets shoved beneath every future release. I verified this — the first simulation produced exactly that mess.The
0.0.17migration note moved into the changeset. Review caught that it would have gone nowhere:release-vscode-extension.ymlbuilt its GitHub Release with--generate-notesand a static body, ignoring the changelog the library and standalone tracks both feed throughextract-changelog.mjs. Fixed in6d45a1c— the extension now uses the same path, so the note reaches the release body:Verification
Every claim above was run, not reasoned. In a throwaway git worktree off this branch, with the real
pnpm exec changeset version:5.1.1;@tumaet/ui(not in the group) goes0.0.1 → 0.0.2as before;apollon-vscode-webviewstays ignored and private.vscode-extension/CHANGELOG.mdhas the shape shown above.node scripts/check-release-taxonomy.mjs— in sync.node scripts/sync-library-version.mjs --check— CDN refs match.pnpm exec changeset status— parses the new config, lists the five patches.actionlint .github/workflows/*.yml— 0 findings across every workflow (was 2 pre-existing before fix(ci): release the VS Code extension only when its version changes #808).prettier --check— clean.One thing I could not run locally:
changeset versionwith the realchangelog-githubgenerator, which resolves each changeset's commit on GitHub and fails on an unpushed one. I swapped in the default generator for the simulation; the GitHub generator only changes how release lines are worded, not which versions are computed. It runs for real in the Version Packages PR.Steps for testing
release.ymlopens (or updates) the Version Packages PR. Confirm it containsapollon-vscode: 1.0.0 → 5.1.1alongside the other three.vscode-extension/package.json, soRelease VS Code Extensionfires,checksees the version changed, and the VSIX is built, attested and published to the Marketplace + Open VSX as5.1.1.workflow_dispatchofRelease VS Code Extensionwithdry_run: trueto prove fix(ci): release the VS Code extension only when its version changes #808's.nvmrcfix on a real runner — it can only fail where there is no checkout.Checklist
pnpm changeset, how) — or this PR doesn't touch a Changesets-tracked package (@tumaet/apollon,@tumaet/webapp,@tumaet/server)feat/fix/…) matches the kind of change — it groups the release notepnpm lint && pnpm format:check && pnpm build && pnpm testlocally — greenNo tests: this is release configuration. It was instead exercised end-to-end with the real
changeset versionin a throwaway worktree, as described above.