Skip to content

fix(ci): group the npm packages that can't move alone - #307

Merged
scttfrdmn merged 1 commit into
mainfrom
ci/dependabot-npm-groups
Aug 3, 2026
Merged

scttfrdmn merged 1 commit into
mainfrom
ci/dependabot-npm-groups

Conversation

@scttfrdmn

Copy link
Copy Markdown
Owner

Closes #306.

Two of the 14 PRs Dependabot opened once .github/dependabot.yml became valid (#288/#289) fail sdk-metrics — and not on a test. They fail at npm install, because npm enforces peer ranges and each moves one half of a pair that has to move together.

#298 — typescript 5.9.3 → 7.0.2:

npm error Found: [email protected]
npm error   dev typescript@"^7.0.2" from the root project
npm error Could not resolve dependency:
npm error peer typescript@">=4.3 <7" from [email protected]

#297 — @typescript-eslint/eslint-plugin 5.62.0 → 8.65.0:

npm error Found: @typescript-eslint/[email protected]
npm error   dev @typescript-eslint/parser@"^5.59.0" from the root project
npm error Could not resolve dependency:
npm error peer @typescript-eslint/parser@"^8.66.0" from @typescript-eslint/[email protected]

Neither is a bad bump. Both are the right target version, proposed in an order that cannot install.

Why here and not for Go

The gomod entry has had a groups: block all along — aws-sdk, production-dependencies, development-dependencies. Neither npm entry did. Ungrouped, Dependabot opens one PR per package and has no way to know two of them are a set.

This surfaced only now because before #288 the whole config was ignored, so Dependabot ran on its defaults and never proposed these at all.

The fix

Two groups on the /sdks/javascript npm entry:

group patterns
typescript-toolchain typescript, ts-jest, jest, @types/jest
typescript-eslint @typescript-eslint/*, eslint

It does not make these automatic — they are still majors, so dependabot-automerge.yml comments and waits for a human. That is the right outcome for a TypeScript 5 → 7 jump.

/docs-platform was checked and is not affected: it has jest and typescript but no ts-jest, so nothing there declares a peer range on the TypeScript version.

Found while looking: the vite alerts need a vitepress major

Recorded rather than fixed here. docs-platform has 3 open vite alerts (one high) patched at 6.4.3, and [email protected] depends on vite: ^5.4.14 — so vite cannot reach 6.x while vitepress is on 1.x. The missing lockfile (#214) is a second blocker, not the only one; committing a lockfile will not close these alerts by itself. Noted on #306 so #214 is not expected to do more than it can.

On not adding a test

A test asserting groups: names particular packages would restate the config rather than check it. The thing that can actually be wrong is the peer range, and only npm knows that. sdk-metrics runs npm install on every PR and is what caught this — that is the gate.

Gates

go build ./... · gofmt -l . clean · go test ./internal/config/ ok (the dependabot config gates live there, including TestDependabotScheduleTimesAreQuoted and TestDependabotLabelsAreDefined).

Two of the 14 PRs Dependabot opened once the config became valid fail sdk-metrics,
and not on a test — they fail at `npm install`, because npm enforces peer ranges
and each moves one half of a pair that has to move together.

  #298  typescript 5.9.3 -> 7.0.2:
        peer typescript@">=4.3 <7" from [email protected]

  #297  @typescript-eslint/eslint-plugin 5.62.0 -> 8.65.0:
        peer @typescript-eslint/parser@"^8.66.0" from the plugin, while parser is
        still pinned ^5.59.0

Neither is a bad bump. Both are the right target version proposed in an order that
cannot install.

The gomod entry has had a groups: block all along — aws-sdk,
production-dependencies, development-dependencies. Neither npm entry did, so
Dependabot opened one PR per package with no way to know two of them are a set.
Adding typescript-toolchain (typescript, ts-jest, jest, @types/jest) and
typescript-eslint (@typescript-eslint/*, eslint) makes each set move as one PR,
which is the only form that resolves.

This does not make them automatic. They are still majors, so
dependabot-automerge.yml comments and waits for a human — right for a
TypeScript 5 -> 7 jump.

/docs-platform was checked and is not affected: it has jest and typescript but no
ts-jest, so nothing there declares a peer range on the TypeScript version.

One thing found while looking, recorded on the issue rather than fixed here: the
three vite alerts need a vitepress major, not a vite bump. [email protected] depends
on vite ^5.4.14, so vite cannot reach the patched 6.4.3 while vitepress is on 1.x.
The missing lockfile (#214) is a second blocker, not the only one.

Closes #306
@scttfrdmn scttfrdmn added type: bug Something isn't working as expected priority: medium Important but not urgent area: ci-cd CI workflows, gates, and release automation labels Aug 3, 2026
@scttfrdmn
scttfrdmn enabled auto-merge (squash) August 3, 2026 19:53
@scttfrdmn
scttfrdmn merged commit 2ba855b into main Aug 3, 2026
27 checks passed
@scttfrdmn
scttfrdmn deleted the ci/dependabot-npm-groups branch September 20, 2026 05:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: ci-cd CI workflows, gates, and release automation priority: medium Important but not urgent type: bug Something isn't working as expected

Projects

None yet

Development

Successfully merging this pull request may close these issues.

npm dev-dependency bumps can't install: Dependabot proposes half of a peer-coupled pair

1 participant