Repository navigation
build(nx): key the version target defaults by the version target - #7134
Merged
overbalance merged 3 commits intoSep 29, 2026
Merged
overbalance merged 3 commits into
overbalance merged 3 commits into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7134 +/- ##
=======================================
Coverage 95.04% 95.04%
=======================================
Files 383 383
Lines 13455 13455
Branches 3094 3094
=======================================
Hits 12788 12788
Misses 667 667 🚀 New features to boost your workflow:
|
Pull request dashboard statusMerged · refreshed 2026-09-29 00:49 UTC Status above doesn't look right?
|
trentm
approved these changes
Sep 29, 2026
github-merge-queue
Bot
removed this pull request from the merge queue due to a conflict with the base branch
Sep 29, 2026
overbalance
enabled auto-merge
September 29, 2026 00:34
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.
Summary
nx.jsonsets the inputs and outputs of the version generator undertargetDefaults["version:update"].version:updateis the root npm script. The per-package target it runs, and thatcompiledepends on, isversion, so no target ever used these defaults.versionis listed incacheableOperations. Without declared outputs, a cache hit replays the terminal output but does not restoresrc/version.ts. That file is gitignored, so if it is deleted while.nx/cachesurvives,npm run compilegets a cache hit forversionand then fails on the missing./versionimport.This PR renames the key to
version, so nx caches and restores{projectRoot}/src/version.ts. The cache key now comes frompackage.jsononly, instead of every file in the project.How Has This Been Tested?
On
main:With this change, the same steps show
@opentelemetry/core:version [local cache]and the file is restored.