Skip to content

Set Renovate rangeStrategy to bump#261

Merged
ryandens merged 1 commit into
mainfrom
fix/renovate-range-strategy
Jun 24, 2026
Merged

Set Renovate rangeStrategy to bump#261
ryandens merged 1 commit into
mainfrom
fix/renovate-range-strategy

Conversation

@ryandens

Copy link
Copy Markdown
Member

Problem

Renovate has been opening dependency PRs that break the build. The default rangeStrategy ("auto", via config:recommended) leaves package.json version ranges untouched whenever the new version is still within the existing range — it only updates the lockfiles. But it rewrote the lockfile entries to new specs (e.g. prettier@^3.8.4, react@^19.2.7) that no longer matched the package.json constraints (^3.2.5, ^19.0.0).

The result: yarn install --frozen-lockfile (in the test-deploy CI job) couldn't find a lockfile entry matching the declared constraint and failed → build broken. This bit #257 (prettier) and #251 (react monorepo), each of which had to be fixed by hand.

Fix

Set "rangeStrategy": "bump". Renovate now bumps the package.json range to the new version and regenerates the lockfiles together, keeping the manifest and lockfiles consistent — the same thing we were doing manually.

Note (follow-up, not in this PR)

The repo carries both yarn.lock and package-lock.json; CI only uses yarn. The redundant package-lock.json is extra surface for these desyncs. Worth removing in a separate change so only one lockfile is maintained.

@ryandens ryandens requested a review from bdoyal June 24, 2026 21:56
The default rangeStrategy ("auto") leaves package.json ranges untouched
when a new version is still within range, updating only the lockfiles.
That rewrote lockfile entries (e.g. prettier@^3.8.4, react@^19.2.7) to
specs that no longer matched the package.json constraints (^3.2.5,
^19.0.0), so `yarn install --frozen-lockfile` failed and broke the
build on every such Renovate PR (#251, #257).

Setting rangeStrategy to "bump" makes Renovate bump the package.json
range to the new version and regenerate the lockfiles together, keeping
the manifest and lockfiles consistent.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ryandens ryandens force-pushed the fix/renovate-range-strategy branch from 5388b4e to 24f669e Compare June 24, 2026 21:56
@ryandens ryandens added this pull request to the merge queue Jun 24, 2026
Merged via the queue into main with commit 0fadc79 Jun 24, 2026
3 checks passed
@ryandens ryandens deleted the fix/renovate-range-strategy branch June 24, 2026 21:59
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.

2 participants