mirror of
https://github.com/Komediruzecki/token-circles.git
synced 2026-10-20 09:46:43 +02:00
ci.yml installed the worker with --no-frozen-lockfile — left over from #397, before worker/pnpm-lock.yaml was committed in #460 — while e2e.yml and deploy-worker.yml were frozen. A Dependabot worker PR, which arrives with package.json bumped and the lockfile untouched (documented limitation), therefore passed Worker Tests against whatever resolved that morning and failed E2E with ERR_PNPM_OUTDATED_LOCKFILE. Three PRs this week (#521, #522, #523) read as a flaky E2E suite. Frozen everywhere, the stale lockfile fails the first job with its real message. dependabot.yml: ignore vitest majors in /worker. @cloudflare/vitest-pool-workers 0.22.0 peers vitest ^4.1.0 and depends on internal Vitest APIs; #522 failed on exactly that. The frontend does not use the pool and is on 5 already. Also notes the --lockfile-only + CI=true variant of the lockfile drill for worktrees without node_modules.
112 lines
5.8 KiB
YAML
112 lines
5.8 KiB
YAML
# Dependency updates.
|
|
#
|
|
# This file is the other half of committing lockfiles, and the two only make sense together.
|
|
#
|
|
# Before: nothing was pinned in worker/ and nothing watched anything anywhere. The argument for
|
|
# leaving it floating was security — "if something urgent lands we want the fix". It does not hold:
|
|
#
|
|
# * Floating is the supply-chain risk, not the mitigation. Every CI run and every prod deploy
|
|
# downloaded whatever npm served at that moment, unreviewed and with no integrity check. That
|
|
# is the exact path a hijacked or republished package takes into a deploy pipeline. A lockfile
|
|
# pins hashes, so a tampered tarball is refused.
|
|
# * "Automatically latest" only helps if somebody notices. Nothing was watching for advisories,
|
|
# nothing opened a PR, nothing tested an upgrade. New versions arrived silently and untested.
|
|
# * Every prod deploy used a different toolchain than CI had tested, so a regression could not be
|
|
# reproduced or rolled back to a known-good build.
|
|
#
|
|
# After: versions are pinned and reproducible, AND upgrades arrive as reviewed, CI-tested PRs.
|
|
# Crucially, Dependabot raises SECURITY updates as soon as an advisory lands regardless of the
|
|
# schedule below — the weekly cadence only paces routine version bumps. Pinning therefore gets
|
|
# security fixes *faster and more visibly* than floating did, because someone is told.
|
|
version: 2
|
|
|
|
updates:
|
|
# The pnpm workspace root — covers frontend/ and packages/.
|
|
- package-ecosystem: npm
|
|
directory: /
|
|
schedule:
|
|
interval: weekly
|
|
day: monday
|
|
open-pull-requests-limit: 5
|
|
groups:
|
|
# One PR for routine dev-tooling bumps instead of a dozen. Majors stay separate: they are
|
|
# the ones that need reading.
|
|
dev-tooling:
|
|
dependency-type: development
|
|
update-types: [minor, patch]
|
|
runtime-patches:
|
|
dependency-type: production
|
|
update-types: [patch]
|
|
ignore:
|
|
# TypeScript 7 is the native port and the ecosystem has not caught up. On the 5.9.3 -> 7.0.2
|
|
# PR, typescript-eslint 8.x crashed outright (`Cannot read properties of undefined (reading
|
|
# 'FunctionType')`) and tsc rejected our own tsconfig: `baseUrl` is removed in 7 and the
|
|
# `paths` entries are all non-relative. That is a migration, not a bump. Revisit when
|
|
# typescript-eslint ships TS 7 support.
|
|
- dependency-name: typescript
|
|
update-types: [version-update:semver-major]
|
|
|
|
# worker/ installs on its own with --ignore-workspace, so it needs its own entry — the root
|
|
# ecosystem does not reach it. This is the one that was completely unpinned.
|
|
#
|
|
# KNOWN LIMITATION — worker PRs from here arrive WITHOUT a lockfile update. Dependabot rewrites
|
|
# worker/package.json and leaves worker/pnpm-lock.yaml alone, so CI's `pnpm install
|
|
# --frozen-lockfile --ignore-workspace` refuses the PR with ERR_PNPM_OUTDATED_LOCKFILE. It is
|
|
# not a stale snapshot; an explicit `@dependabot recreate` produced the same manifest-only diff.
|
|
# The cause is that pnpm-workspace.yaml does not list worker/, so the nested standalone lockfile
|
|
# is not one Dependabot's pnpm updater manages.
|
|
#
|
|
# The drill, until that changes: check the branch out and commit the lockfile it should have had.
|
|
#
|
|
# cd worker && pnpm install --no-frozen-lockfile --ignore-workspace
|
|
#
|
|
# From a worktree with no node_modules, `--lockfile-only` regenerates the file without installing
|
|
# anything — and needs `CI=true`, or pnpm aborts on the missing TTY while still exiting 0.
|
|
#
|
|
# Everything lands in ONE group deliberately. Each of these PRs costs the manual step above, so
|
|
# five small PRs a week is five times the handling of one — and they conflict with each other on
|
|
# the lockfile besides. Majors still break out on their own: those are the ones worth reading.
|
|
- package-ecosystem: npm
|
|
directory: /worker
|
|
schedule:
|
|
interval: weekly
|
|
day: monday
|
|
open-pull-requests-limit: 5
|
|
groups:
|
|
worker-deps:
|
|
patterns: ['*']
|
|
update-types: [minor, patch]
|
|
ignore:
|
|
# wrangler is the deploy toolchain and the E2E dev server. It ships a new minor most weeks,
|
|
# each carrying a different miniflare, and an unattended bump is how a `wrangler dev` that
|
|
# crashes mid-run reaches main. Patches and security advisories still come through; a minor
|
|
# is a deliberate choice made against a green E2E run.
|
|
- dependency-name: wrangler
|
|
update-types: [version-update:semver-minor, version-update:semver-major]
|
|
# vitest 5 is out, but @cloudflare/vitest-pool-workers 0.22.0 peers `vitest ^4.1.0` and says
|
|
# at runtime that it "depends on internal Vitest APIs that are not protected by semantic-
|
|
# versioning guarantees". #522 (4.1.11 -> 5.0.0) failed Worker Tests on exactly that. Lift
|
|
# this when pool-workers ships a release whose peer range includes 5; the frontend, which
|
|
# does not use the pool, is already on 5.
|
|
- dependency-name: vitest
|
|
update-types: [version-update:semver-major]
|
|
# TypeScript 7 is the native port and the ecosystem has not caught up. On the 5.9.3 -> 7.0.2
|
|
# PR, typescript-eslint 8.x crashed outright (`Cannot read properties of undefined (reading
|
|
# 'FunctionType')`) and tsc rejected our own tsconfig: `baseUrl` is removed in 7 and the
|
|
# `paths` entries are all non-relative. That is a migration, not a bump. Revisit when
|
|
# typescript-eslint ships TS 7 support.
|
|
- dependency-name: typescript
|
|
update-types: [version-update:semver-major]
|
|
|
|
# The actions themselves. A compromised third-party action runs with the workflow's token, so
|
|
# these matter as much as anything in package.json.
|
|
- package-ecosystem: github-actions
|
|
directory: /
|
|
schedule:
|
|
interval: weekly
|
|
day: monday
|
|
open-pull-requests-limit: 5
|
|
groups:
|
|
actions:
|
|
update-types: [minor, patch]
|