Skip to content

fix: enable nx release to bootstrap from disk when no tags exist []#37

Closed
Lisa White (whitelisab) wants to merge 1 commit into
mainfrom
fix/update-release
Closed

fix: enable nx release to bootstrap from disk when no tags exist []#37
Lisa White (whitelisab) wants to merge 1 commit into
mainfrom
fix/update-release

Conversation

@whitelisab

Copy link
Copy Markdown
Contributor

Summary

  • nx release in CI is failing after PR feat: add packages/client with fetchExperience and delivery client [AIS-147] #30 merged because no release tags exist in this repo yet — nx's default is to compute the next version from a matching prior tag ({projectName}@{version}), and with none present it bails
  • Adds fallbackCurrentVersionResolver: \"disk\" to nx.json, which tells nx to read the baseline version from each package's package.json when no matching tag is found; subsequent releases pick up from tags normally
  • Fixes the client package's placeholder version (0.0.0-determined-by-semantic-release) — it wouldn't parse as semver under the disk resolver

The CI error

NX  No git tags matching pattern "{projectName}@{version}" for project "client" were found.
You will need to create an initial matching tag to use as a base for determining the next version.

Why this fix instead of --first-release

--first-release is a one-shot escape hatch that requires either running nx release manually with vault access, or a temporary workflow tweak followed by a revert. Adding the disk-fallback resolver is a one-line change that:

  • fixes CI without a manual dance,
  • self-heals for any future new package added to the workspace, and
  • doesn't change behavior once tags exist (the resolver is only consulted when a matching tag can't be found).

Test plan

  • npm run format:check passes (already verified locally)
  • After merge: watch the release workflow run cleanly on main and produce initial tags for all 5 packages

Generated with Claude Code

nx release requires prior tags matching `{projectName}@{version}` to compute
version bumps. Since no such tags exist yet in this repo, the first release
attempt fails for every package. Adding `fallbackCurrentVersionResolver: "disk"`
tells nx to read the baseline version from each package.json when no tag is
present, making initial releases self-bootstrapping.

Also fixes the client package's placeholder version — it was left over from
a semantic-release scaffold and doesn't parse as semver.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@whitelisab Lisa White (whitelisab) changed the title fix: enable nx release to bootstrap from disk when no tags exist fix: enable nx release to bootstrap from disk when no tags exist [] Jul 14, 2026
@whitelisab

Copy link
Copy Markdown
Contributor Author

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