Repository navigation
chore(deps): update dependencies and move to Vitest 5 - #149
Conversation
Published 1.1.4 corrupts Vitest 5's module evaluator while rewriting `import.meta.url`, so no test file starts: cloudflare/workers-sdk#15500 Its preview build declares workspace siblings as URLs, so miniflare and wrangler are pinned back to what 1.1.4 resolves. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN
Vitest 5 stopped cascading a top-level `perFile` into glob-keyed entries, and with no global metric thresholds the outer one no longer reaches anything. Each glob now carries the per-file intent itself. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN
Inline projects extend the root config by default in Vitest 5, so the spread that carried these into each project is now a duplicate of what they already inherit. Verified by an assertion-free test failing under both the worker and source projects. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN
Unscoped, they also rewrote the peer range of the repo's own wrangler and vite-plugin, so a later wrangler bump would have been silently pinned back. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
🚀 Deploying Preview to Cloudflare 🚀Preview URL: https://chore-vitest-website.eve0415.workers.dev (commit 01bda87)This URL reflects your latest Preview deploymentPreview Deployments by commit
|
There was a problem hiding this comment.
🟡 Changes recommended
The devcontainer still installs pnpm@11.21.0, which is inconsistent with the repo’s pinned pnpm@12.3.4 and likely to break pnpm install --frozen-lockfile with the updated lockfile.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Updates the repo’s tooling/dependencies to current versions and migrates the test setup to Vitest 5, including the config adjustments required by Vitest 5’s changed project/coverage behaviors and a temporary pin/override strategy for a Cloudflare Vitest plugin preview build.
Changes:
- Bump Vitest + coverage provider, Playwright, Wrangler, oxlint/oxfmt/oxc, and other devDependencies; update pnpm version and lockfile accordingly.
- Adjust
vitest.config.tsfor Vitest 5 config inheritance and per-globperFilecoverage threshold behavior. - Add workspace overrides to keep
@cloudflare/vitest-plugin’s preview build usable under pnpm.
File summaries
| File | Description |
|---|---|
vitest.config.ts |
Moves shared test options to the root test block and updates coverage threshold entries for Vitest 5 behavior changes. |
pnpm-workspace.yaml |
Adds scoped overrides for @cloudflare/vitest-plugin transitive deps to avoid pkg.pr.new “exotic subdeps” issues. |
pnpm-lock.yaml |
Refreshes the full dependency graph/lockfile for the version bumps and preview dependency source. |
package.json |
Updates dependency pins, Node runtime pin (devEngines), and the pinned pnpm packageManager. |
.devcontainer/devcontainer.json |
Updates the base image and GitHub CLI feature version for the devcontainer. |
.devcontainer/devcontainer-lock.json |
Updates the devcontainer feature lock to match the new GitHub CLI feature version. |
Review details
- Files reviewed: 5/6 changed files
- Comments generated: 2
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| "name": "eve0415 website devcontainer", | ||
| "image": "mcr.microsoft.com/devcontainers/typescript-node:5.0.3-24-trixie", | ||
| "image": "mcr.microsoft.com/devcontainers/typescript-node:5.1.2-24-trixie", | ||
| "onCreateCommand": "npm install -g pnpm@11.21.0", |
The base image installs pnpm globally already, so the pinned 11.21.0 only downgraded it in place before `packageManager` pulled it forward again. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN
`engines.node` and `.node-version` were left behind by the runtime pin that moved with the dependencies. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN
Routine dependency refresh, plus the config changes Vitest 5 needs.
Dependencies
Vitest and
@vitest/coverage-istanbulgo to 5.0.0, wrangler to 4.129.0, Playwright to 1.63.0, oxlint/oxfmt/oxc and the remaining devDependencies to their current releases, and pnpm to 12.3.4. Node moves to 24.20.0 in all three places that pin it —devEngines.runtime,engines.nodeand.node-version.@cloudflare/vitest-pluginis the exception: it runs from the preview build of cloudflare/workers-sdk#15500 rather than a published version. Published 1.1.4 corrupts Vitest 5's module evaluator while rewritingimport.meta.url, so under Vitest 5 no test file starts at all. That preview declares its workspace siblings as pkg.pr.new URLs, which pnpm rejects as exotic subdeps, sopnpm-workspace.yamlpinsminiflareandwranglerback to what published 1.1.4 resolves. The overrides are scoped to the plugin — unscoped, they also rewrote the peer range of the repo's own wrangler and@cloudflare/vite-plugin, which would have silently pinned a later wrangler bump back. Both the dependency and the overrides come out once the fix ships in a release.Devcontainer
The image moves to
5.1.2-24-trixieand the github-cli feature to 1.1.2.onCreateCommandis gone:typescript-nodebuilds onjavascript-node, which usesghcr.io/devcontainers/features/node:2at"version": "none"— that setting skips only the nvm install, and the feature still installs pnpm globally. The pinnedpnpm@11.21.0was therefore downgrading the image's own copy in place, whichpackageManagerthen pulled forward again on the first invocation.Test config
Two behaviour changes in Vitest 5 reach
vitest.config.ts:SHAREDspread each project carried is a duplicate of what they already inherit. Removed; the options move to the roottestblock.sequencewas already at the root for the separate reason noted in the old comment, and stays there.perFile. With no global metric thresholds in this config, the outerperFilereached nothing, so each glob entry now carriesperFile: trueitself.Review
CI is the check that matters here — the lint, build, vitest and Playwright steps all run against the preview plugin build for the first time.
🤖 Generated with Claude Code
https://claude.ai/code/session_01G9YZoAViKnPNMejgYADysN