Skip to content

feat: add CLI compatibility manifest for template version pinning#333

Open
pkosiec wants to merge 7 commits intomainfrom
pkosiec/appkit-version-pinning
Open

feat: add CLI compatibility manifest for template version pinning#333
pkosiec wants to merge 7 commits intomainfrom
pkosiec/appkit-version-pinning

Conversation

@pkosiec
Copy link
Copy Markdown
Member

@pkosiec pkosiec commented Apr 30, 2026

Summary

Add cli-compat.json — a compatibility manifest mapping Databricks CLI versions to compatible AppKit template and Agent Skills versions (design doc, Option C).

What's included

  • cli-compat.json — manifest with next + versioned CLI entries, each mapping to {appkit, skills} versions
  • tools/check-cli-compat.ts — CI validator ensuring:
    • Valid JSON structure with required next key
    • All keys are next or valid semver (X.Y.Z)
    • All entries have exactly appkit and skills fields (no extra keys)
    • next versions are >= all versioned entries
    • Versioned keys are in ascending semver order
    • At least one versioned entry besides next
  • CI integration — validation step added to lint_and_typecheck job
  • Unit tests for the validator and compareSemver
  • CONTRIBUTING.md — documents manifest format, resolution rules, and update procedure (aligned with design doc)
  • CLAUDE.md — documents the check-cli-compat tool
  • .claude/skills/bump-cli-compat.md — Claude Code skill to bump versions and create a PR

Test plan

  • pnpm exec tsx tools/check-cli-compat.ts passes
  • Unit tests pass (pnpm test)
  • Biome lint/format clean
  • CI passes on the PR

@pkosiec pkosiec force-pushed the pkosiec/appkit-version-pinning branch 2 times, most recently from 2a3fd34 to 8d8dc43 Compare April 30, 2026 15:20
pkosiec added 7 commits April 30, 2026 18:12
Add cli-compat.json that maps CLI versions to compatible AppKit template
and Agent Skills versions. This enables decoupling template delivery from
CLI release cycles — older CLI versions automatically receive a compatible
template version.

Also add tools/check-cli-compat.ts validation script and CI step to
prevent malformed manifests from being merged.

Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
- Validate that "next" appkit/skills versions are >= all versioned
  entries to prevent accidental downgrades for newest CLIs
- Add check-cli-compat.ts to CLAUDE.md tools listing

Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
- Reject prerelease suffixes in SEMVER regex (compareSemver
  produces NaN for them, silently bypassing next>=max check)
- Check appkit and skills fields independently in next>=max
  validation (previously a missing appkit skipped skills too)
- Require at least one versioned CLI entry besides "next"

Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
- Add "Updating the CLI compatibility manifest" section to CONTRIBUTING.md
- Reduce cli-compat.json to two initial entries (next + 0.299.0)

Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
- Bail out of cross-entry comparison when structure validation fails,
  preventing NaN-based semver comparisons on invalid entries
- Reject unexpected fields in manifest entries
- Validate versioned keys are in ascending semver order
- Extract validateCliCompat() for testability
- Add 20 unit tests covering all validation branches

Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
- Rewrite "When to update" section in CONTRIBUTING.md to match design doc
  (evals step, "last 3 CLI versions" detail, future automation note)
- Add bump-cli-compat Claude Code skill for updating the manifest

Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
Signed-off-by: Pawel Kosiec <pawel.kosiec@databricks.com>
@pkosiec pkosiec force-pushed the pkosiec/appkit-version-pinning branch from 8d8dc43 to 9b43085 Compare April 30, 2026 16:12
@pkosiec pkosiec marked this pull request as ready for review April 30, 2026 16:12
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