fix(ci): drop per-rule rangeStrategy from npm-majors packageRule (#94) #112
No reviewers
Labels
No labels
area:auth
area:ci
area:db
area:infra
area:native
area:pwa
area:service
epic
feature
foundation
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
james/carol!112
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "94-renovate-config-fix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #94.
What happened
Renovate's config validator started rejecting the combination of
matchUpdateTypes+rangeStrategyin the same packageRule. The bot filed #94 and stopped opening PRs until the config is fixed:The offending rule:
The intent was: for npm major updates, override the default
update-lockfilestrategy tobumpso the package.json range actually gets changed (sinceupdate-lockfilealone can't satisfy an out-of-range update).Fix
Remove the per-rule
"rangeStrategy": "bump"and rely on the root-level"rangeStrategy": "update-lockfile"'s documented fallback behavior: when the lockfile can't satisfy an in-range update (which is exactly what a major is), Renovate automatically falls back toreplace, which produces the same package.json range changebumpwould have for caret/tilde ranges. The packageRule keepsmatchUpdateTypes: ["major"]+ group + label +automerge: falsewithout the forbidden override.The architectural intent — lockfile-only by default, separate PR + human review for majors — is preserved. Only the mechanism shifted from per-rule override to implicit root-level fallback.
Files
renovate.json"rangeStrategy": "bump"from the npm-major-bumps packageRule; expand the rule'sdescriptionto explain the new mechanism + cite this issuedocs/ci.mdreplacebehavior instead of the now-impossible per-rule overrideTest plan
python3 -c 'import json; json.load(open("renovate.json"))'— clean.npx --yes --package=renovate@latest -- renovate-config-validator—Config validated successfully against 1 file(s).Why ADR-0009 was not edited
ADR-0009 mentions
rangeStrategy: "bump"in its prose. Per ADR-0001's immutability rule, ADRs aren't edited after acceptance — they record the architectural decision at a point in time, and the decision (lockfile-only default + separate PR for majors + never-auto-merge) is unchanged here. Only the syntactic mechanism shifted, driven by an external validator tightening.docs/ci.mdis the current-truth source for config syntax; ADR-0009 stays as the historical reasoning record.Heads up: stray validator warning
Locally, an older Renovate (37.x) also flags
github-actions.managerFilePatternsas an "invalid option" — that's a field-renaming churn between Renovate versions, not a real problem (your live instance, which filed #94, clearly accepts the option since #94's error was about something else). No action needed unless Renovate upstream actually removes the field.0afa90631d7c601e6d5c