fix: PLUGIN_VERSION drifted from package.json, and config omitted defaults.color - #19
Merged
Conversation
…efaults.color Two loose ends from the colour release. `tabby-cctabs` 0.1.4 shipped with PLUGIN_VERSION = '0.1.5', so /api/health — and therefore `cctabs doctor` — reported a version that was never published. The renumber from 0.1.5 to 0.1.4 caught package.json but not the constant. Behaviourally harmless, since plugin features are feature-detected through `capabilities` rather than compared by version. That is exactly why this pair has now drifted twice and both times survived review: nothing fails. So this adds a test asserting the two agree, rather than a third note in CLAUDE.md asking the next person to remember. It reads the plugin's files from `src/` because that is where `npm test` looks; drop it if the coupling isn't worth it. Separately, `cctabs config` printed claude.flags, defaults.workspace and defaults.prefix but not defaults.color — so the one command whose job is "show me my config" omitted a setting it was honouring, which reads as the colour not having been picked up at all. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Deploying cctabs with
|
| Latest commit: |
60305b0
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://7338e608.cctabs.pages.dev |
| Branch Preview URL: | https://fix-plugin-version-drift.cctabs.pages.dev |
… npm test The guard test added in this PR asserts PLUGIN_VERSION matches tabby-plugin/package.json, but it only runs under `npm test` — which this workflow never invokes, and which the CLI's release workflow runs on a separate, independently versioned tag. A plugin bump made without touching the constant would therefore still publish before any test saw it, which is precisely how the drift arrived both times. The tag-vs-package.json step already has both values in hand, so it checks the constant too. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L96RQtEkx5rJEesxqCdNut
Colour was applied in the spawn/recreate path only. Whether a restored tab is attached or recreated turns on whether its shell happens to be alive, and after a terminal restart that comes down to which tabs got focused first — Tabby spawns a recovered tab's shell only on focus. So a restored fleet came back half-coloured, in an order nothing in the user's model predicts. Found while planning a real 65-tab restart, where the split would have been roughly 64 recreated (coloured) and 1 attached (not), varying with how much the user clicked around before running restore. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
motin
added a commit
that referenced
this pull request
Aug 27, 2026
The Release flow section still described `npm publish` with an Automation token. Both packages moved to OIDC trusted publishing gated on the `release` environment, so there is no token, and pushing a tag queues a publish rather than performing one — which is the part worth knowing, since a tag whose run is never approved looks released and isn't. Also writes down the no-gaps rule: a version that was tagged but never published gets its tag re-pointed, not abandoned. That is what happened to v0.5.2, whose run sat waiting while #19 landed on top of it. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L96RQtEkx5rJEesxqCdNut
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two loose ends spotted while installing the published
tabby-cctabs0.1.4 on a real fleet.PLUGIN_VERSIONdrifted, againPublished
tabby-cctabs@0.1.4ships withPLUGIN_VERSION = '0.1.5', so/api/health— and thereforecctabs doctor— reports a version that was never published:My colour PR set both to
0.1.5consistently; the renumber down to0.1.4caughtpackage.jsonand missed the constant. Entirely my kind of mistake to have set up, so: fixed, plus a guard.Behaviourally harmless — plugin features are feature-detected through
capabilities, never compared by version, so nothing breaks. That is exactly why it has now drifted twice and survived review both times (once a release behind, per the note inCLAUDE.md; now once ahead). Nothing fails, so nobody notices.Hence a test rather than a third note asking the next person to remember:
It lives in
src/because that's wherenpm testlooks (bun test src/), which does mean a CLI test reaching intotabby-plugin/. I think the trade is worth it for an invariant that's now failed twice, but it's the one part of this PR I'd understand you dropping — the alternative is a plugin-side test setup that doesn't exist yet.cctabs configomitteddefaults.colorIt printed
claude.flags,defaults.workspaceanddefaults.prefix, so the one command whose job is "show me what my config is" silently left out a setting it was honouring. Concretely, withcolor = "orange"set and working:which reads as "the colour wasn't picked up" when in fact it resolves fine. My omission in the colour PR.
Testing
npm test— 226 pass, 0 fail.npm run typecheckandnpm run buildclean. The guard test deliberately usesfileURLToPath(new URL(...))rather than Bun'simport.meta.dir, so typecheck passes without depending on@types/bunresolving.Verified on a live 53-tab fleet: CLI 0.5.1 from npm has both features, plugin 0.1.4 installed via
cctabs install-tabby-plugin --no-restart(the--no-restartflag is genuinely useful here — restarting Tabby under 53 tabs is not a casual act), and[backends.enterprise] color = "blue"+[defaults] color = "orange"resolves to#0275d8/#f0ad4eas intended.🤖 Generated with Claude Code