fix: remediate v1 audit dependency advisories - #2319
Conversation
🦋 Changeset detectedLatest commit: d5fd8ea The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
📝 WalkthroughWalkthroughThis PR migrates the project's base branch from ChangesDependency Upgrade and Branch Migration
🎯 2 (Simple) | ⏱️ ~12 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
⚔️ Resolve merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 10
🧹 Nitpick comments (8)
crates/create-farm-rs/templates/electron/svelte/package.json (1)
26-29: Svelte 5 upgrade is largely backwards-compatible; only migrate to runes if needed
While Svelte 5 introduces runes and associated syntax/lifecycle changes, the official migration docs state Svelte 5 is largely backwards-compatible with Svelte 4, so this template should keep working with existing Svelte 4-style components. If any build/runtime issues appear (e.g., deprecations), use the official migration tool (npx sv migrate svelte-5) to update incrementally.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@crates/create-farm-rs/templates/electron/svelte/package.json` around lines 26 - 29, The template currently pins Svelte to a v5 release ("svelte": "^5.56.1") which may force rune-based migrations; change the dependency to a Svelte 4 line (e.g., "^4.x") so existing Svelte 4-style components keep working and avoid unexpected migration steps, and align related packages ("`@sveltejs/vite-plugin-svelte`" and "svelte-check") to versions compatible with Svelte 4 as needed; update package.json entries for "svelte", "`@sveltejs/vite-plugin-svelte`", and "svelte-check" to Svelte-4-compatible versions and run a local install/test to verify no breaking changes..github/workflows/ci.yaml (1)
89-108: Consider adding explicit permissions to the type-check job.The static analysis tool flagged that this job inherits default permissions rather than declaring explicit, minimal permissions. While this doesn't block the current PR (the pattern pre-exists), consider adding a
permissions:block scoped to what this job actually needs (likelycontents: readfor checkout andpull-requests: readfor changeset status checks).🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/ci.yaml around lines 89 - 108, The type-check job currently inherits default permissions; add an explicit permissions block under the type-check job (the job named "type-check") scoped to only what's needed — e.g., set contents: read for actions/checkout and pull-requests: read for the "Changesets Check" step — so the job declares minimal permissions instead of using defaults.Source: Linters/SAST tools
examples/vite-adapter-react/package.json (1)
9-10: ⚡ Quick winConsider aligning react-router-dom to match react-router version.
react-routeris at^6.30.4whilereact-router-domis at^6.22.3. While both are v6 and should be compatible, keeping them aligned ensures consistent behavior and includes the latest bug fixes.📦 Align versions
"react-dom": "18", "react-router": "^6.30.4", - "react-router-dom": "^6.22.3" + "react-router-dom": "^6.30.4" },🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/vite-adapter-react/package.json` around lines 9 - 10, The package.json has mismatched versions for react-router and react-router-dom (react-router is ^6.30.4 while react-router-dom is ^6.22.3); update the react-router-dom dependency to match the react-router version (e.g., set "react-router-dom": "^6.30.4") so both packages use the same v6 release and include the same bug fixes and behavior; locate and edit the dependencies section in package.json where "react-router" and "react-router-dom" are declared.examples/react-query/package.json (1)
10-11: ⚡ Quick winConsider aligning react-router-dom to match react-router version.
react-routeris at^6.30.4whilereact-router-domis at^6.22.3. While both are v6 and should be compatible, keeping them aligned (both at^6.30.4) ensures consistent behavior and includes the latest bug fixes and improvements.📦 Align versions
"react-dom": "18", "react-router": "^6.30.4", - "react-router-dom": "^6.22.3" + "react-router-dom": "^6.30.4" },🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/react-query/package.json` around lines 10 - 11, Update the dependency versions so react-router-dom matches react-router; change the "react-router-dom" entry to use the same version specifier as "react-router" (i.e., ^6.30.4) to keep both libraries aligned and ensure consistent behavior and fixes across the repo.js-plugins/postcss/package.json (1)
48-48: ⚡ Quick winConsider using a caret range instead of pinning the exact version.
The PostCSS version is pinned to
8.5.15without a caret, while all other files in this PR use^8.5.15. This prevents automatic patch updates that may include important security fixes. Given thatpeerDependenciesaccepts>=8.0.0, using^8.5.15indevDependencieswould be more consistent and maintainable.📦 Recommended fix to use caret range
- "postcss": "8.5.15", + "postcss": "^8.5.15",🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@js-plugins/postcss/package.json` at line 48, The "postcss" devDependency is pinned to "8.5.15"; update the "postcss" entry in package.json under devDependencies to use a caret range (^8.5.15) so it matches other files and allows patch updates; locate the "postcss" key in package.json and change its version string to "^8.5.15" and run your package manager (install/lockfile update) to refresh lockfiles.examples/nestjs/package.json (2)
32-32: ⚡ Quick winInconsistent
@types/nodeversion with template.The template uses
@types/node: ^18.19.67while this example uses^24.10.4. This inconsistency may confuse users about the minimum supported Node.js version. Consider aligning both files to the same Node.js type definitions, preferably using the minimum supported version (v18) in the template and optionally a newer version in examples if demonstrating newer features.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/nestjs/package.json` at line 32, The `@types/node` version in examples/nestjs package.json is inconsistent with the template (uses ^24.10.4 vs template's ^18.19.67); update the examples/nestjs dependency "`@types/node`" in package.json to match the template's ^18.19.67 (or decide to standardize on the minimum supported v18 across template and examples) so all package.json files use the same Node type definitions and avoid confusion about supported Node versions.
39-39: 💤 Low valueConsider pinning
farmupversion for reproducibility.Using
"latest"forfarmupreduces build reproducibility. While this may be acceptable for examples to showcase the newest features, consider using a specific version range (e.g.,^0.0.12as in the template) for more predictable builds.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/nestjs/package.json` at line 39, The dependency in package.json uses "farmup": "latest", which hurts reproducible builds; update the package.json dependency for "farmup" to a fixed version or semver range (for example ^0.0.12 or a specific patch like 0.0.12) so builds are deterministic, and run npm/yarn install to verify the lockfile updates and examples still build; locate the "farmup" entry in package.json to make this change.crates/create-farm-rs/templates/svelte/package.json (1)
18-26: Tauri Svelte template’s@sveltejs/vite-plugin-svelteversion matches itsvite@^6.4.2upgrade.
crates/create-farm-rs/templates/tauri/svelte/package.jsonusesvite@^6.4.2with@sveltejs/vite-plugin-svelte@^5.1.1, whilecrates/create-farm-rs/templates/svelte/package.json(andtauri2,electron,vite-adapter-svelte) use@sveltejs/vite-plugin-svelte@^4.0.4. This aligns with the plugins’ peer dependency requirements (v5.1.1expectsvite: ^6.0.0,v4.0.4expectsvite: ^5.0.0), so the mismatch appears intentional for Vite 6 compatibility.Optional: add a brief note in the template to document that rationale and avoid future “version inconsistency” concerns.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@crates/create-farm-rs/templates/svelte/package.json` around lines 18 - 26, The svelte template's package.json currently pins `@sveltejs/vite-plugin-svelte` to an older major (^4.0.4) while another template uses ^5.1.1 to match vite@^6.4.2; either update the svelte template's `@sveltejs/vite-plugin-svelte` dependency to ^5.1.1 (and align other templates like tauri2/electron/vite-adapter-svelte) to be compatible with vite@^6, or keep the older plugin and add a short comment/README in the template explaining that `@sveltejs/vite-plugin-svelte` is intentionally older to match vite ^5.x and that the tauri template uses ^5.x to support vite ^6.x; specifically edit the package.json dependency "`@sveltejs/vite-plugin-svelte`" (and related template package.json files) or add the note next to the dependency entry to document the rationale.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@crates/create-farm-rs/templates/nestjs/package.json`:
- Around line 24-26: Update the NestJS template to declare the Node >=20
requirement and document it: in package.json add an "engines" field (e.g.,
"engines": {"node": ">=20"}) so users are prevented from installing the pinned
`@nestjs/core/`@nestjs/common v11.1.24 on older Node versions, and add a short
note to the template README stating that NestJS v11 requires Node.js 20+ (and
that the current dependency pins
`@nestjs/common/`@nestjs/core/@nestjs/platform-express at 11.1.24 are
intentionally used and are outside the known advisory ranges mentioned).
In `@crates/create-farm-rs/templates/svelte/package.json`:
- Around line 16-20: The package.json currently pins "svelte":"^5.56.1" and
"svelte-check":"^4.3.4" but svelte-check's peerDependencies don't cover stable
Svelte 5.x, causing npm run check peer mismatch; update the template's
dependency constraints by bumping "svelte-check" to a version that declares
support for stable Svelte 5 (or relax the svelte-check constraint and add a
compatible peer/engines note), ensuring package.json entries for "svelte" and
"svelte-check" are consistent so npm run check succeeds with Svelte 5.56.x;
reference the package.json dependency keys "svelte" and "svelte-check" when
making the change.
In `@examples/arco-pro/package.json`:
- Around line 33-34: Package.json pins mismatched router libs (react-router v6
vs react-router-dom v5) which breaks runtime; fix by aligning versions and
updating code: either downgrade "react-router" to a v5 release to match current
v5-style usage (keep existing code in src/layout.tsx and src/index.tsx that uses
Switch, Redirect, useHistory, and Route component=...) or upgrade
"react-router-dom" to v6 and migrate routing code—replace Switch with Routes,
Redirect with Navigate, useHistory with useNavigate, and change <Route ...
component={...} /> usages to the v6 element prop; update package.json
dependencies accordingly and adjust imports/usages in src/layout.tsx and
src/index.tsx to match the chosen version.
In `@examples/vanilla-extract/package.json`:
- Line 17: The package.json for the vanilla-extract example declares "vite":
"^6.4.2" while using "`@vanilla-extract/vite-plugin`@^4.0.13", whose
peerDependencies do not include Vite 6; update the dependency resolution in
examples/vanilla-extract/package.json by either (A) bumping
`@vanilla-extract/vite-plugin` to a release that lists "vite" with ^6.x in its
peerDependencies, or (B) pinning "vite" to a supported range (e.g., <=6.4.1 or
^5.x) so it matches the plugin's peerDependencies; ensure the package.json entry
strings for "vite" or "`@vanilla-extract/vite-plugin`" are adjusted accordingly
and run install to verify no peer dependency warnings.
In `@examples/vite-adapter-vue2/package.json`:
- Line 22: Verify that axios@1.17.0 in package.json is acceptable: confirm npm
registry availability for "axios@1.17.0" and check GitHub security advisories
for axios to ensure no unpatched HIGH vulnerabilities apply; then run the
project tests and any integration flows that set axios request configuration to
ensure you do not rely on prototype-inherited config values (check uses of
socketPath, params, paramsSerializer) because v1.17.0 hardens own-property
checks; if any code relies on prototype inheritance, change it to set properties
directly on the config object or pin/rollback the axios version in package.json
accordingly.
In `@examples/vue-antdv/package.json`:
- Line 10: The package.json currently lists xlsx-js-style in devDependencies
while the app (examples/vue-antdv/src/home.vue) imports read, utils, and
writeFileXLSX from xlsx-js-style at runtime; move xlsx-js-style from
devDependencies to dependencies so production installs include it, and safely
remove the unused xlsx entry (uninstall or delete from
dependencies/devDependencies) since no runtime code imports xlsx; ensure
package.json's dependencies include "xlsx-js-style" and that
examples/vue-antdv/src/home.vue still imports read, utils, writeFileXLSX without
changes.
In `@examples/vue-ssr/package.json`:
- Line 9: The package.json dependency entry for "express": "^4.22.2" is present
and the security scan shows no advisories affecting 4.22.2; confirm this by
checking the Express 4.22.x changelog/release notes for breaking changes or
deprecations and either leave the dependency as "express": "^4.22.2" or update
the version range if you intentionally want a newer non-breaking patch/minor
release, then commit the verified package.json change; reference the "express"
dependency entry in package.json when making the update or leaving it as-is.
In `@js-plugins/visualizer/package.json`:
- Line 21: The package.json currently pins "axios": "^1.17.0" and (implicitly)
uses "ws": "^8.21.0"; confirm these exact versions are safe by updating the
lockfile (run npm/yarn/pnpm install to regenerate lockfile), run the full test
suite and any integration steps to ensure no behavioral or breaking changes, and
cross-check changelogs/release notes for axios and ws for breaking changes; if
any security advisories still apply or tests fail, update the dependency
versions in package.json to the minimally safe patched releases and regenerate
the lockfile, then re-run tests to validate.
In `@js-plugins/vue/package.json`:
- Line 46: The package dependency "`@types/node`" in js-plugins/vue package.json
is set to ^24.10.4 which targets TS 5.8+ and will conflict with the workspace
TypeScript (^4.9.4); either pin "`@types/node`" to a Node 18 / TS 4.9–compatible
release (e.g. an 18.x `@types/node`) in package.json, OR upgrade the package's
TypeScript devDependency (and tsconfig if needed) to >=5.8 so `@types/node`@24 is
supported; update the dependency entry for "`@types/node`" or bump the package's
TypeScript version accordingly and run the package install/build to verify no
type errors.
In `@package.json`:
- Line 29: CI is still using Node 18 but Vitest 4 requires Node >=20; update
.github/workflows/ci.yaml to set actions/setup-node node-version to 20 (or 22)
for the jobs running npm run test, npm run test-e2e and vitest bench, and update
package.json "engines.node" to "^20.0.0 || ^22.0.0 || >=24.0.0" to match
vitest@4.1.8/@vitest/coverage-v8; after making these changes run the full test
matrix (pnpm test and pnpm test-e2e) and fix any runtime failures reported by
vitest.
---
Nitpick comments:
In @.github/workflows/ci.yaml:
- Around line 89-108: The type-check job currently inherits default permissions;
add an explicit permissions block under the type-check job (the job named
"type-check") scoped to only what's needed — e.g., set contents: read for
actions/checkout and pull-requests: read for the "Changesets Check" step — so
the job declares minimal permissions instead of using defaults.
In `@crates/create-farm-rs/templates/electron/svelte/package.json`:
- Around line 26-29: The template currently pins Svelte to a v5 release
("svelte": "^5.56.1") which may force rune-based migrations; change the
dependency to a Svelte 4 line (e.g., "^4.x") so existing Svelte 4-style
components keep working and avoid unexpected migration steps, and align related
packages ("`@sveltejs/vite-plugin-svelte`" and "svelte-check") to versions
compatible with Svelte 4 as needed; update package.json entries for "svelte",
"`@sveltejs/vite-plugin-svelte`", and "svelte-check" to Svelte-4-compatible
versions and run a local install/test to verify no breaking changes.
In `@crates/create-farm-rs/templates/svelte/package.json`:
- Around line 18-26: The svelte template's package.json currently pins
`@sveltejs/vite-plugin-svelte` to an older major (^4.0.4) while another template
uses ^5.1.1 to match vite@^6.4.2; either update the svelte template's
`@sveltejs/vite-plugin-svelte` dependency to ^5.1.1 (and align other templates
like tauri2/electron/vite-adapter-svelte) to be compatible with vite@^6, or keep
the older plugin and add a short comment/README in the template explaining that
`@sveltejs/vite-plugin-svelte` is intentionally older to match vite ^5.x and that
the tauri template uses ^5.x to support vite ^6.x; specifically edit the
package.json dependency "`@sveltejs/vite-plugin-svelte`" (and related template
package.json files) or add the note next to the dependency entry to document the
rationale.
In `@examples/nestjs/package.json`:
- Line 32: The `@types/node` version in examples/nestjs package.json is
inconsistent with the template (uses ^24.10.4 vs template's ^18.19.67); update
the examples/nestjs dependency "`@types/node`" in package.json to match the
template's ^18.19.67 (or decide to standardize on the minimum supported v18
across template and examples) so all package.json files use the same Node type
definitions and avoid confusion about supported Node versions.
- Line 39: The dependency in package.json uses "farmup": "latest", which hurts
reproducible builds; update the package.json dependency for "farmup" to a fixed
version or semver range (for example ^0.0.12 or a specific patch like 0.0.12) so
builds are deterministic, and run npm/yarn install to verify the lockfile
updates and examples still build; locate the "farmup" entry in package.json to
make this change.
In `@examples/react-query/package.json`:
- Around line 10-11: Update the dependency versions so react-router-dom matches
react-router; change the "react-router-dom" entry to use the same version
specifier as "react-router" (i.e., ^6.30.4) to keep both libraries aligned and
ensure consistent behavior and fixes across the repo.
In `@examples/vite-adapter-react/package.json`:
- Around line 9-10: The package.json has mismatched versions for react-router
and react-router-dom (react-router is ^6.30.4 while react-router-dom is
^6.22.3); update the react-router-dom dependency to match the react-router
version (e.g., set "react-router-dom": "^6.30.4") so both packages use the same
v6 release and include the same bug fixes and behavior; locate and edit the
dependencies section in package.json where "react-router" and "react-router-dom"
are declared.
In `@js-plugins/postcss/package.json`:
- Line 48: The "postcss" devDependency is pinned to "8.5.15"; update the
"postcss" entry in package.json under devDependencies to use a caret range
(^8.5.15) so it matches other files and allows patch updates; locate the
"postcss" key in package.json and change its version string to "^8.5.15" and run
your package manager (install/lockfile update) to refresh lockfiles.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 2b569b12-1b11-417b-bd3f-aa01f3d7aac3
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (58)
.changeset/config.json.changeset/fresh-audits-v1.md.changeset/remove-cli-inquirer-v1.md.github/workflows/ci.yaml.github/workflows/release-plz.yaml.github/workflows/release.yaml.github/workflows/rust-test.yamlcrates/create-farm-rs/templates/electron/preact/package.jsoncrates/create-farm-rs/templates/electron/react/package.jsoncrates/create-farm-rs/templates/electron/solid/package.jsoncrates/create-farm-rs/templates/electron/svelte/package.jsoncrates/create-farm-rs/templates/electron/vanilla/package.jsoncrates/create-farm-rs/templates/electron/vue/package.jsoncrates/create-farm-rs/templates/nestjs/package.jsoncrates/create-farm-rs/templates/solid/package.jsoncrates/create-farm-rs/templates/svelte/package.jsoncrates/create-farm-rs/templates/tauri/solid/package.jsoncrates/create-farm-rs/templates/tauri/svelte/package.jsoncrates/create-farm-rs/templates/tauri2/solid/package.jsoncrates/create-farm-rs/templates/tauri2/svelte/package.jsonexamples/arco-pro/package.jsonexamples/electron/package.jsonexamples/js-plugin-cache/package.jsonexamples/nestjs/package.jsonexamples/node-server/package.jsonexamples/pandacss/package.jsonexamples/postcss/package.jsonexamples/preact/package.jsonexamples/react-antd-mobile/package.jsonexamples/react-antd/package.jsonexamples/react-query/package.jsonexamples/react-ssr/package.jsonexamples/react/package.jsonexamples/script-entry/package.jsonexamples/server-proxy/package.jsonexamples/solid-ssr/package.jsonexamples/solid/package.jsonexamples/tailwind/package.jsonexamples/vanilla-extract/package.jsonexamples/vite-adapter-react/package.jsonexamples/vite-adapter-solid/package.jsonexamples/vite-adapter-svelte/package.jsonexamples/vite-adapter-tsconfig-paths/package.jsonexamples/vite-adapter-vue/package.jsonexamples/vite-adapter-vue2/package.jsonexamples/vue-antdv/package.jsonexamples/vue-ssr/package.jsonexamples/vue/package.jsonjs-plugins/electron/package.jsonjs-plugins/postcss/package.jsonjs-plugins/solid/package.jsonjs-plugins/tailwindcss/package.jsonjs-plugins/visualizer/package.jsonjs-plugins/vue/package.jsonpackage.jsonpackages/cli/package.jsonpackages/core/package.jsonpackages/runtime/package.json
| "@nestjs/common": "^11.1.24", | ||
| "@nestjs/core": "^11.1.24", | ||
| "@nestjs/platform-express": "^11.1.24", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Verify NestJS v11 package versions and check for security advisories
echo "=== Checking NestJS package versions on npm ==="
for pkg in "`@nestjs/common`@11.1.24" "`@nestjs/core`@11.1.24" "`@nestjs/platform-express`@11.1.24" "`@nestjs/cli`@11.0.14" "`@nestjs/schematics`@11.0.9" "`@nestjs/testing`@11.1.24"; do
echo "Checking $pkg"
npm view "$pkg" version 2>/dev/null || echo " ❌ Version not found"
done
echo ""
echo "=== Checking for security advisories ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 10, ecosystem: NPM, package: "`@nestjs/common`") {
nodes {
advisory {
summary
severity
publishedAt
}
vulnerableVersionRange
firstPatchedVersion {
identifier
}
}
}
}'Repository: farm-fe/farm
Length of output: 968
🌐 Web query:
NestJS v10 to v11 migration guide breaking changes
💡 Result:
Migrating from NestJS v10 to v11 involves several key updates and breaking changes, primarily driven by underlying framework upgrades. The official migration guide serves as the primary reference for these transitions [1][2]. Key Breaking Changes and Migration Requirements: Node.js Version Requirement NestJS v11 requires Node.js version 20 or higher; support for Node.js v16 and v18 has been dropped [2][3]. HTTP Adapter Upgrades NestJS v11 defaults to Express v5 and supports Fastify v5 [1][4]. - Express v5: This transition introduces changes to route path matching and query parsing behavior. Specifically, the path matching algorithm is more strict. Wildcards must now be named (e.g., use /splat instead of just /), and optional segment support using '?' is replaced by curly brace syntax (e.g., /:file{.:ext}) [4]. - Query Parsing: Express v5 uses a simpler default parser, meaning complex nested objects or arrays in query strings may not be parsed as expected [4]. - Middleware Path Matching: The path-to-regexp version used in @nestjs/platform-fastify no longer supports the (.*) syntax for matching all paths; named wildcards must be used instead [1][5]. Dynamic Modules The framework no longer generates predictable hashes for dynamic modules [1]. Instead, module equivalence is determined by object references. To share a dynamic module across multiple parts of an application, it should be assigned to a variable and imported from that shared reference [1][6]. Module Exports Support for promises in module 'exports' has been removed, as this pattern was considered a breaking or unstable implementation [3][7]. Package-Specific Changes - @nestjs/config: Version 4.0.0 includes breaking changes, specifically regarding the order in which configuration variables are processed by the ConfigService#get method [1][6]. - @nestjs/cache-manager: Version 3.0.0 includes breaking changes [2][7]. - ESLint: The framework has upgraded to ESLint v9, which may require updates to your local ESLint configuration (often shifting to flat config/eslint.config.mjs) [2][3][8]. General Advice While many of these changes are designed to be seamless, users should review the specific migration guides for Express v5 and Fastify v5 if they rely heavily on custom routing or middleware configurations [1][4]. For a complete list of changes, always consult the official migration guide at https://docs.nestjs.com/migration-guide [1].
Citations:
- 1: https://docs.nestjs.com/migration-guide
- 2: https://github.com/nestjs/nest/releases/tag/v11.0.0
- 3: https://newreleases.io/project/github/nestjs/nest/release/v11.0.0
- 4: https://deepwiki.com/nestjs/docs.nestjs.com/13.2-migration-guide
- 5: https://github.com/nestjs/docs.nestjs.com/blob/ba85c6a2/content/migration.md
- 6: https://github.com/nestjs/docs.nestjs.com/blob/master/content/migration.md
- 7: https://newreleases.io/project/npm/@nestjs/core/release/11.0.0
- 8: https://kinesis-school-of-programming.gitbook.io/nestjs-unleashed/introduction/upgrading-packages-ncu/nestjs-v10-greater-than-v11
🏁 Script executed:
#!/bin/bash
set -euo pipefail
root="."
template_dir="crates/create-farm-rs/templates/nestjs"
echo "=== Files under NestJS template ==="
ls -la "$template_dir" || true
echo
echo "=== package.json (relevant sections) ==="
if [ -f "$template_dir/package.json" ]; then
sed -n '1,120p' "$template_dir/package.json"
else
echo "Missing: $template_dir/package.json"
fi
echo
echo "=== Search for Node/engines hints ==="
rg -n "\"engines\"|node\s*:" "$template_dir" || true
echo
echo "=== Search for likely Express v5 wildcard/path-to-regexp patterns ==="
rg -n "@(Get|Post|Put|Delete|Patch|All)\(" "$template_dir" || true
rg -n "\"\\*\"|\\*/|/\\*|\\(\\.\\*\\)|pathToRegexp|splat|\\?.*\\b" "$template_dir" || true
echo
echo "=== Search for dynamic module / exports promise patterns ==="
rg -n "`@Module`\\(|exports\\s*:\\s*\\[|exports\\s*:\\s*\\{|exports\\s*:\\s*\\w+|forRootAsync\\(|useFactory" "$template_dir" || trueRepository: farm-fe/farm
Length of output: 6610
🏁 Script executed:
#!/bin/bash
set -euo pipefail
template_dir="crates/create-farm-rs/templates/nestjs"
echo "=== Inspect app.module.ts ==="
sed -n '1,200p' "$template_dir/src/app.module.ts" || true
echo
echo "=== Inspect app.controller.ts ==="
sed -n '1,200p' "$template_dir/src/app.controller.ts" || true
echo
echo "=== Inspect e2e/unit tests (if any) ==="
ls -la "$template_dir/test" || true
find "$template_dir/test" -maxdepth 3 -type f -name "*.ts" -print | sort | head -n 20
for f in $(find "$template_dir/test" -maxdepth 3 -type f -name "*.ts" 2>/dev/null | sort); do
echo "---- $f ----"
sed -n '1,160p' "$f"
echo
done
echo "=== Search for Node version / engines in README/package ==="
rg -n "engines|node\s*>=|Node\.js|required.*node|nvm" "$template_dir/README.md" "$template_dir/package.json" || true
echo "=== Search for route wildcard/path-to-regexp patterns in src ==="
rg -n "\\*\\b|/\\*|pathToRegexp|splat|\\(\\.\\*\\)|\\?.*=" "$template_dir/src" || true
echo "=== Query security advisories for upgraded NestJS packages ==="
pkgs=("`@nestjs/common`" "`@nestjs/core`" "`@nestjs/platform-express`" "`@nestjs/testing`" "`@nestjs/cli`" "`@nestjs/schematics`")
for p in "${pkgs[@]}"; do
echo "---- $p ----"
gh api graphql -f query="
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: \"$p\") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}" 2>/dev/null || true
doneRepository: farm-fe/farm
Length of output: 3581
🏁 Script executed:
#!/bin/bash
set -euo pipefail
f="crates/create-farm-rs/templates/nestjs/package.json"
nl -ba "$f" | sed -n '15,60p'Repository: farm-fe/farm
Length of output: 99
🏁 Script executed:
#!/bin/bash
set -euo pipefail
f="crates/create-farm-rs/templates/nestjs/package.json"
echo "=== package.json lines 20-45 ==="
awk 'NR>=20 && NR<=45 {print NR ":" $0}' "$f"
echo
echo "=== package.json lines 45-90 ==="
awk 'NR>=45 && NR<=90 {print NR ":" $0}' "$f"
echo
echo "=== README Node version hints ==="
rg -n "Node\.js|engines|>=\s*20|node\s*20|LTS" crates/create-farm-rs/templates/nestjs/README.md || trueRepository: farm-fe/farm
Length of output: 2015
Ensure NestJS v11 upgrade is safe for template users (Node requirement + advisory ranges)
The pinned NestJS v11 versions in crates/create-farm-rs/templates/nestjs/package.json (24-26, 33-35) exist on npm, and the known GitHub security advisory version ranges for @nestjs/common (< 11.0.16) and @nestjs/core (<= 11.1.17) do not include 11.1.24—so these specific pins don’t land in the reported vulnerable ranges.
The main breaking-change risk to address is that NestJS v11 requires Node.js >= 20; the template currently has no engines.node and the README doesn’t state the Node requirement. Express v5 routing changes are likely low-impact here since the template only defines a simple @Get() endpoint (no wildcard/path-to-regexp patterns).
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@crates/create-farm-rs/templates/nestjs/package.json` around lines 24 - 26,
Update the NestJS template to declare the Node >=20 requirement and document it:
in package.json add an "engines" field (e.g., "engines": {"node": ">=20"}) so
users are prevented from installing the pinned `@nestjs/core/`@nestjs/common
v11.1.24 on older Node versions, and add a short note to the template README
stating that NestJS v11 requires Node.js 20+ (and that the current dependency
pins `@nestjs/common/`@nestjs/core/@nestjs/platform-express at 11.1.24 are
intentionally used and are outside the known advisory ranges mentioned).
| "@sveltejs/vite-plugin-svelte": "^4.0.4", | ||
| "@tsconfig/svelte": "^5.0.4", | ||
| "core-js": "^3.36.1", | ||
| "svelte": "^4.2.12", | ||
| "svelte-check": "^3.6.8", | ||
| "svelte": "^5.56.1", | ||
| "svelte-check": "^4.3.4", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Verify Svelte dependency versions exist and check for security advisories
echo "=== Checking if versions exist on npm ==="
npm view svelte@5.56.1 version 2>/dev/null || echo "⚠️ svelte@5.56.1 not found"
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 version 2>/dev/null || echo "⚠️ `@sveltejs/vite-plugin-svelte`@4.0.4 not found"
npm view svelte-check@4.3.4 version 2>/dev/null || echo "⚠️ svelte-check@4.3.4 not found"
echo ""
echo "=== Checking latest versions ==="
npm view svelte version
npm view `@sveltejs/vite-plugin-svelte` version
npm view svelte-check version
echo ""
echo "=== Checking compatibility notes ==="
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 peerDependencies
echo ""
echo "=== Checking for security advisories ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 10, ecosystem: NPM, package: "svelte") {
nodes {
advisory {
summary
severity
publishedAt
}
vulnerableVersionRange
firstPatchedVersion {
identifier
}
}
}
}'Repository: farm-fe/farm
Length of output: 4771
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Inspect Svelte template files for runes/reactivity ==="
TEMPLATE_DIR="crates/create-farm-rs/templates/svelte"
# List a small set of relevant files
find "$TEMPLATE_DIR" -type f \( -name "*.svelte" -o -name "*.js" -o -name "*.ts" -o -name "vite.config.*" -o -name "package.json" \) | sed "s|^./||" | sort | head -n 200
echo ""
echo "=== Search for rune syntax ($state/$derived/$effect) and other Svelte 5-specific patterns ==="
rg -n --hidden --no-ignore-vcs \
'\$state|\$derived|\$effect|\$props|\$bindable|rune:' \
"$TEMPLATE_DIR" || true
echo ""
echo "=== Search for classic reactive statements ($:) usage ==="
rg -n --hidden --no-ignore-vcs '\$:' "$TEMPLATE_DIR" || true
echo ""
echo "=== Check npm peerDependencies for svelte-check and vite-plugin-svelte ==="
npm view svelte-check@4.3.4 version
npm view svelte-check@4.3.4 peerDependencies || echo "No peerDependencies"
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 peerDependencies || true
echo ""
echo "=== Check GH security advisories for svelte-check and vite-plugin-svelte ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: "svelte-check") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'
gh api graphql -f query='
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: "`@sveltejs/vite-plugin-svelte`") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'Repository: farm-fe/farm
Length of output: 564
🏁 Script executed:
#!/bin/bash
set -euo pipefail
TEMPLATE_DIR="crates/create-farm-rs/templates/svelte"
echo "=== Inspect Svelte template files for runes/reactivity ==="
find "$TEMPLATE_DIR" -type f \( -name "*.svelte" -o -name "*.js" -o -name "*.ts" -o -name "vite.config.*" -o -name "package.json" \) | sed "s|^./||" | sort
echo ""
echo "=== Search for rune syntax ($state/$derived/$effect) and other Svelte 5-specific patterns ==="
rg -n --hidden --no-ignore-vcs '\$state|\$derived|\$effect|\$props|\$bindable|rune:' "$TEMPLATE_DIR" || true
echo ""
echo "=== Search for classic reactive statements ($:) usage ==="
rg -n --hidden --no-ignore-vcs '\$:' "$TEMPLATE_DIR" || true
echo ""
echo "=== Check npm peerDependencies for svelte-check and vite-plugin-svelte ==="
npm view svelte-check@4.3.4 version
npm view svelte-check@4.3.4 peerDependencies || echo "No peerDependencies"
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 peerDependencies || true
echo ""
echo "=== Check GH security advisories for svelte-check and vite-plugin-svelte ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: "svelte-check") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'
gh api graphql -f query='
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: "`@sveltejs/vite-plugin-svelte`") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'Repository: farm-fe/farm
Length of output: 564
🏁 Script executed:
#!/bin/bash
set -euo pipefail
TEMPLATE_DIR="crates/create-farm-rs/templates/svelte"
echo "=== Inspect Svelte template files for runes/reactivity ==="
find "$TEMPLATE_DIR" -type f \( -name "*.svelte" -o -name "*.js" -o -name "*.ts" -o -name "vite.config.*" -o -name "package.json" \) | sed "s|^./||" | sort
echo ""
echo "=== Search for rune syntax (\$state/\$derived/\$effect) and other Svelte 5-specific patterns ==="
rg -n --hidden --no-ignore-vcs '\$state|\$derived|\$effect|\$props|\$bindable|rune:' "$TEMPLATE_DIR" || true
echo ""
echo "=== Search for classic reactive statements (\$:) usage ==="
rg -n --hidden --no-ignore-vcs '\$:' "$TEMPLATE_DIR" || true
echo ""
echo "=== Check npm peerDependencies for svelte-check and vite-plugin-svelte ==="
npm view svelte-check@4.3.4 version
npm view svelte-check@4.3.4 peerDependencies || echo "No peerDependencies"
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 peerDependencies || true
echo ""
echo "=== Check GH security advisories for svelte-check and vite-plugin-svelte ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: "svelte-check") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'
gh api graphql -f query='
{
securityVulnerabilities(first: 20, ecosystem: NPM, package: "`@sveltejs/vite-plugin-svelte`") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'Repository: farm-fe/farm
Length of output: 2511
🏁 Script executed:
#!/bin/bash
set -euo pipefail
TEMPLATE_DIR="crates/create-farm-rs/templates/svelte"
echo "=== App.svelte ==="
sed -n '1,200p' "$TEMPLATE_DIR/src/App.svelte"
echo ""
echo "=== Counter.svelte ==="
sed -n '1,200p' "$TEMPLATE_DIR/src/lib/Counter.svelte"Repository: farm-fe/farm
Length of output: 1285
🏁 Script executed:
#!/bin/bash
set -euo pipefail
TEMPLATE_PKG="crates/create-farm-rs/templates/svelte/package.json"
echo "=== Template package.json (dependencies + relevant devDependencies) ==="
cat -n "$TEMPLATE_PKG" | sed -n '1,120p'
echo ""
echo "=== GH security advisories for svelte (larger page) ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 50, ecosystem: NPM, package: "svelte") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}'Repository: farm-fe/farm
Length of output: 4356
🏁 Script executed:
#!/bin/bash
set -euo pipefail
TEMPLATE_DIR="crates/create-farm-rs/templates/svelte"
echo "=== svelte.config.js ==="
sed -n '1,200p' "$TEMPLATE_DIR/svelte.config.js"
echo ""
echo "=== farm.config.ts ==="
sed -n '1,200p' "$TEMPLATE_DIR/farm.config.ts"
echo ""
echo "=== npm view: svelte-check@4.3.4 (dependencies fields that may indicate Svelte 5 support) ==="
npm view svelte-check@4.3.4 peerDependencies
npm view svelte-check@4.3.4 peerDependenciesMeta || true
npm view svelte-check@4.3.4 engines || true
echo ""
echo "=== npm view: `@sveltejs/vite-plugin-svelte`@4.0.4 (peerDependencies) ==="
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 peerDependencies
npm view `@sveltejs/vite-plugin-svelte`@4.0.4 peerDependenciesMeta || trueRepository: farm-fe/farm
Length of output: 3258
Reconcile Svelte 5 upgrade verification (versions/security OK; svelte-check peer range needs attention)
svelte@^5.56.1,@sveltejs/vite-plugin-svelte@^4.0.4, andsvelte-check@^4.3.4all exist on npm, andsveltelatest is5.56.3(so5.56.1is not anomalously high).@sveltejs/vite-plugin-svelte@4.0.4peer deps accept stable Svelte 5 (svelte: ^5.0.0-next.96 || ^5.0.0).svelte-check@4.3.4declares peer depssvelte: ^4.0.0 || ^5.0.0-next.0; this does not cover stable5.56.x, so verify/updatesvelte-checkto avoid breakingnpm run check(peer mismatch).- Template Svelte code uses classic component/reactivity syntax (no runes like
$state/$derived/$effect), so the “runes reactivity model” compatibility point doesn’t apply to these templates. - Security: GH advisories for
svelteare patched starting at5.55.7; with5.56.1you’re outside the vulnerable ranges shown. No GH advisories were returned forsvelte-checkor@sveltejs/vite-plugin-svelte.
[dependency_check]
-
Flagging: remaining actionable item is the
svelte-checkpeerDependency range vs stable Svelte 5. -
Action: update
svelte-check(or the template constraints) sonpm run checkworks with Svelte5.56.x. -
Template runes migration is not required for current template files.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@crates/create-farm-rs/templates/svelte/package.json` around lines 16 - 20,
The package.json currently pins "svelte":"^5.56.1" and "svelte-check":"^4.3.4"
but svelte-check's peerDependencies don't cover stable Svelte 5.x, causing npm
run check peer mismatch; update the template's dependency constraints by bumping
"svelte-check" to a version that declares support for stable Svelte 5 (or relax
the svelte-check constraint and add a compatible peer/engines note), ensuring
package.json entries for "svelte" and "svelte-check" are consistent so npm run
check succeeds with Svelte 5.56.x; reference the package.json dependency keys
"svelte" and "svelte-check" when making the change.
| "react-router": "^6.30.4", | ||
| "react-router-dom": "^5.3.0", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Check for React Router v5 patterns that need migration to v6
echo "=== Checking for React Router v5 patterns ==="
rg -nP --type=ts --type=tsx --type=js --type=jsx -C2 '\b(Switch|useHistory|Redirect)\b' examples/arco-pro/
echo -e "\n=== Checking Route component patterns ==="
rg -nP --type=ts --type=tsx --type=js --type=jsx -C2 '<Route\s+component=' examples/arco-pro/Repository: farm-fe/farm
Length of output: 219
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== package.json (dependency versions) ==="
cat -n examples/arco-pro/package.json | sed -n '1,120p'
echo
echo "=== Search for react-router imports in arco-pro ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' "from ['\"]react-router-dom['\"]" examples/arco-pro || true
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' "from ['\"]react-router['\"]" examples/arco-pro || true
echo
echo "=== Search for React Router v5 patterns ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C2 "\b(Switch|useHistory|Redirect)\b" examples/arco-pro || true
echo
echo "=== Search for React Router v6 patterns ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C2 "\b(Routes|useNavigate|Navigate)\b" examples/arco-pro || true
echo
echo "=== Search for <Route component= vs <Route element= usage ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C1 "<Route\s+component=" examples/arco-pro || true
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C1 "<Route\s+element=" examples/arco-pro || trueRepository: farm-fe/farm
Length of output: 8973
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== package.json (dependency versions) ==="
cat -n examples/arco-pro/package.json | sed -n '1,120p'
echo
echo "=== Search for react-router imports in arco-pro ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' "from ['\"]react-router-dom['\"]" examples/arco-pro || true
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' "from ['\"]react-router['\"]" examples/arco-pro || true
echo
echo "=== Search for React Router v5 patterns ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C2 "\b(Switch|useHistory|Redirect)\b" examples/arco-pro || true
echo
echo "=== Search for React Router v6 patterns ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C2 "\b(Routes|useNavigate|Navigate)\b" examples/arco-pro || true
echo
echo "=== Search for <Route component= vs <Route element= usage ==="
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C1 "<Route\s+component=" examples/arco-pro || true
rg -n --glob='examples/arco-pro/**/*.{js,jsx,ts,tsx,mjs,cjs}' -C1 "<Route\s+element=" examples/arco-pro || trueRepository: farm-fe/farm
Length of output: 8973
Critical: React Router peer/API mismatch (v6 react-router + v5 react-router-dom) will break runtime.
examples/arco-pro/package.json pins "react-router": "^6.30.4" (line 33) while "react-router-dom": "^5.3.0" (line 34). The code under examples/arco-pro/src/ is written for react-router-dom v5 (uses Switch, Redirect, useHistory, and <Route ... component={...} /> in src/layout.tsx and src/index.tsx). Align versions by either downgrading react-router to v5 (keeping the v5 code) or upgrading to react-router-dom v6 and migrating the routing code to v6 APIs (Routes, Navigate, useNavigate, element prop).
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/arco-pro/package.json` around lines 33 - 34, Package.json pins
mismatched router libs (react-router v6 vs react-router-dom v5) which breaks
runtime; fix by aligning versions and updating code: either downgrade
"react-router" to a v5 release to match current v5-style usage (keep existing
code in src/layout.tsx and src/index.tsx that uses Switch, Redirect, useHistory,
and Route component=...) or upgrade "react-router-dom" to v6 and migrate routing
code—replace Switch with Routes, Redirect with Navigate, useHistory with
useNavigate, and change <Route ... component={...} /> usages to the v6 element
prop; update package.json dependencies accordingly and adjust imports/usages in
src/layout.tsx and src/index.tsx to match the chosen version.
| "@farmfe/core": "workspace:*", | ||
| "typescript": "^5.4.3", | ||
| "vite": "^5.2.6" | ||
| "vite": "^6.4.2" |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Check `@vanilla-extract/vite-plugin` compatibility with Vite 6
# Check the plugin's peer dependencies
echo "=== Checking `@vanilla-extract/vite-plugin` peer dependencies ==="
npm view `@vanilla-extract/vite-plugin`@4.0.13 peerDependencies
# Check for latest version that might support Vite 6
echo -e "\n=== Checking latest `@vanilla-extract/vite-plugin` version ==="
npm view `@vanilla-extract/vite-plugin` versions --json | jq -r '.[-5:]'
# Check if there are any open issues about Vite 6 compatibility
echo -e "\n=== Searching for Vite 6 compatibility issues ==="
gh search issues --repo vanilla-extract-css/vanilla-extract "vite 6" --limit 5Repository: farm-fe/farm
Length of output: 2335
🏁 Script executed:
#!/bin/bash
# Description: Test vanilla-extract example build
cd examples/vanilla-extract
pnpm install
pnpm run buildRepository: farm-fe/farm
Length of output: 2266
Fix Vite 6 compatibility for @vanilla-extract/vite-plugin
examples/vanilla-extract/package.jsonsets Vite to^6.4.2while using@vanilla-extract/vite-plugin@^4.0.13@vanilla-extract/vite-plugin@4.0.13declarespeerDependencies.vite: '^4.0.3 || ^5.0.0'(no^6), so Vite 6 is likely unsupported with this plugin version- Upstream integration/search shows Vite 6-related breakages and even a pin to
vite <= 6.4.1in a workaround, so consider bumping the plugin to a version whosepeerDependencies.viteincludes^6.x(and/or aligning Vite to<= 6.4.1)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/vanilla-extract/package.json` at line 17, The package.json for the
vanilla-extract example declares "vite": "^6.4.2" while using
"`@vanilla-extract/vite-plugin`@^4.0.13", whose peerDependencies do not include
Vite 6; update the dependency resolution in
examples/vanilla-extract/package.json by either (A) bumping
`@vanilla-extract/vite-plugin` to a release that lists "vite" with ^6.x in its
peerDependencies, or (B) pinning "vite" to a supported range (e.g., <=6.4.1 or
^5.x) so it matches the plugin's peerDependencies; ensure the package.json entry
strings for "vite" or "`@vanilla-extract/vite-plugin`" are adjusted accordingly
and run install to verify no peer dependency warnings.
| "@farmfe/cli": "workspace:^1.0.0", | ||
| "@farmfe/core": "workspace:^1.0.11", | ||
| "axios": "^1.7.2", | ||
| "axios": "^1.17.0", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Verify axios version 1.17.0 exists and check for security advisories
# Check npm for axios 1.17.0
curl -s https://registry.npmjs.org/axios/1.17.0 | jq -r '.version // "VERSION NOT FOUND"'
# Get latest 1.x version
curl -s https://registry.npmjs.org/axios | jq -r '.["dist-tags"].latest'
# Check for security advisories on axios
gh api graphql -f query='
{
securityVulnerabilities(first: 10, ecosystem: NPM, package: "axios") {
nodes {
advisory {
summary
severity
publishedAt
}
vulnerableVersionRange
firstPatchedVersion {
identifier
}
}
}
}'Repository: farm-fe/farm
Length of output: 2810
🌐 Web query:
axios 1.17.0 release notes breaking changes
💡 Result:
Axios version 1.17.0, released on June 1, 2026, includes several hardening measures and bug fixes, but no explicit breaking changes are documented in the release notes [1][2]. Key updates in 1.17.0 include: Config Hardening: The release introduced guards for socketPath, params, and paramsSerializer using own-property checks [1][2]. This is designed to prevent inherited prototype values from affecting request behavior, addressing potential SSRF-sensitive paths [1][2]. HTTP Compression: Support for zstd response decompression was added for the Node HTTP adapter [1][2]. This is controlled by the transitional.advertiseZstdAcceptEncoding configuration [1][2]. Authentication Handling: The release restored Basic authentication on same-origin Node redirects while maintaining the existing behavior of stripping credentials for cross-origin requests [1][2]. It also aligned the fetch adapter's behavior for URL-embedded Basic auth with the HTTP adapter [1][2]. Header Handling: Axios now silently skips empty or whitespace-only header names instead of throwing errors [1][2]. This change aims to match parsed-header behavior and prevent crashes in React Native environments [1][2]. Proxy TLS: User-defined httpsAgent TLS options are now preserved when tunneling HTTPS requests through HTTP CONNECT proxies [1][2]. While the release includes significant hardening (specifically regarding config property access), it is categorized as a standard update rather than a major breaking release [1][2]. Users should verify if their specific implementation relies on prototype-inherited configuration properties, as these will no longer be respected [1][2].
Citations:
- 1: https://github.com/axios/axios/releases/tag/v1.17.0
- 2: https://github.com/axios/axios/blob/v1.x/CHANGELOG.md
Confirm axios@1.17.0 availability and risks—only notable change is config own-property hardening.
- npm registry contains
axios@1.17.0. - GitHub security advisories returned for axios are HIGH and all show
firstPatchedVersionat or below1.16.0(so they should not affect1.17.0). - axios
v1.17.0release notes describe standard hardening/bug fixes with no explicit breaking changes, but it tightens behavior around prototype-inherited configuration values (e.g., own-property guards forsocketPath,params,paramsSerializer), which could affect this example only if it relies on prototype inheritance.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/vite-adapter-vue2/package.json` at line 22, Verify that axios@1.17.0
in package.json is acceptable: confirm npm registry availability for
"axios@1.17.0" and check GitHub security advisories for axios to ensure no
unpatched HIGH vulnerabilities apply; then run the project tests and any
integration flows that set axios request configuration to ensure you do not rely
on prototype-inherited config values (check uses of socketPath, params,
paramsSerializer) because v1.17.0 hardens own-property checks; if any code
relies on prototype inheritance, change it to set properties directly on the
config object or pin/rollback the axios version in package.json accordingly.
| "vue": "^3.3.0", | ||
| "vue-router": "^4.2.1", | ||
| "xlsx": "^0.18.5" | ||
| "vue-router": "^4.2.1" |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Search for xlsx imports or usage in the vue-antdv example
# Search for xlsx imports (not xlsx-js-style)
rg -nP --type=ts --type=js --type=vue -C3 '\bimport\s+.*\s+from\s+["\']xlsx["\']' examples/vue-antdv/ || echo "No xlsx imports found"
# Search for require statements
rg -nP --type=ts --type=js --type=vue -C3 '\brequire\s*\(\s*["\']xlsx["\']\s*\)' examples/vue-antdv/ || echo "No xlsx require statements found"Repository: farm-fe/farm
Length of output: 125
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "== package.json (dependencies/devDependencies) =="
cat examples/vue-antdv/package.json
echo "== Search for runtime imports/requires of 'xlsx' (exclude xlsx-js-style) =="
rg -n --type-add 'vue:vue' -t js -t ts -t vue --glob 'examples/vue-antdv/**/*.{js,ts,vue}' \
-e "import[[:space:]]+[^;]*[[:space:]]from[[:space:]]*['\"]xlsx['\"]" \
examples/vue-antdv/ || echo "No xlsx imports found"
rg -n --type-add 'vue:vue' -t js -t ts -t vue --glob 'examples/vue-antdv/**/*.{js,ts,vue}' \
-e "require[[:space:]]*\\([[:space:]]*['\"]xlsx['\"]" \
examples/vue-antdv/ || echo "No xlsx require statements found"
echo "== Search for any 'xlsx' token usage (including comments/docs) =="
rg -n -S --glob 'examples/vue-antdv/**/*.{js,ts,vue,json,md}' '\bxlsx\b' examples/vue-antdv/ || echo "No 'xlsx' token usage found"
echo "== Search for 'XLSX' global usage =="
rg -n -S --glob 'examples/vue-antdv/**/*.{js,ts,vue}' '\bXLSX\b' examples/vue-antdv/ || echo "No 'XLSX' global usage found"Repository: farm-fe/farm
Length of output: 1464
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "== home.vue (relevant section) =="
nl -ba examples/vue-antdv/src/home.vue | sed -n '1,120p'
echo
echo "== Search for xlsx-js-style imports =="
rg -n --type=js --type=ts --type=vue --glob 'examples/vue-antdv/**/*.{js,ts,vue}' \
-e "from[[:space:]]*['\"]xlsx-js-style['\"]" examples/vue-antdv/ || echo "No xlsx-js-style imports found"Repository: farm-fe/farm
Length of output: 151
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "== home.vue (relevant section) =="
cat -n examples/vue-antdv/src/home.vue | sed -n '1,160p'
echo
echo "== Search for xlsx-js-style imports =="
rg -n --type=js --type=ts --type=vue --glob 'examples/vue-antdv/**/*.{js,ts,vue}' \
-e "from[[:space:]]*['\"]xlsx-js-style['\"]" examples/vue-antdv/ || echo "No xlsx-js-style imports found"Repository: farm-fe/farm
Length of output: 1454
Remove xlsx safely; fix placement of xlsx-js-style.
- No runtime code in
examples/vue-antdv/imports or requires thexlsxpackage directly. - The app code in
examples/vue-antdv/src/home.vueimportsxlsx-js-style(read,utils,writeFileXLSX) and uses it to generate the exported XLSX file. - Since
xlsx-js-styleis imported by the app, movexlsx-js-stylefromdevDependenciestodependencies(or document/install assumptions) sofarm build/startwon’t fail when only production deps are installed.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/vue-antdv/package.json` at line 10, The package.json currently lists
xlsx-js-style in devDependencies while the app (examples/vue-antdv/src/home.vue)
imports read, utils, and writeFileXLSX from xlsx-js-style at runtime; move
xlsx-js-style from devDependencies to dependencies so production installs
include it, and safely remove the unused xlsx entry (uninstall or delete from
dependencies/devDependencies) since no runtime code imports xlsx; ensure
package.json's dependencies include "xlsx-js-style" and that
examples/vue-antdv/src/home.vue still imports read, utils, writeFileXLSX without
changes.
| "clsx": "^1.2.1", | ||
| "core-js": "^3.30.1", | ||
| "express": "^4.18.2", | ||
| "express": "^4.22.2", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Verify express version 4.22.2 exists and check for security advisories
# Check npm for express 4.22.2
curl -s https://registry.npmjs.org/express/4.22.2 | jq -r '.version // "VERSION NOT FOUND"'
# Check for security advisories on express
gh api graphql -f query='
{
securityVulnerabilities(first: 10, ecosystem: NPM, package: "express") {
nodes {
advisory {
summary
severity
publishedAt
}
vulnerableVersionRange
firstPatchedVersion {
identifier
}
}
}
}'Repository: farm-fe/farm
Length of output: 2350
Express ^4.22.2: version exists; no reported security advisories affect 4.22.2
- npm registry reports express version 4.22.2.
- The retrieved GitHub security advisories for
expressall havevulnerableVersionRangevalues that exclude 4.22.2; the closest match is a withdrawn advisory for versions < 4.22.0, with the first patched version 4.22.0. - Upgrade still warrants a quick check of Express 4.22.x changelog/release notes for any breaking changes/deprecations.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/vue-ssr/package.json` at line 9, The package.json dependency entry
for "express": "^4.22.2" is present and the security scan shows no advisories
affecting 4.22.2; confirm this by checking the Express 4.22.x changelog/release
notes for breaking changes or deprecations and either leave the dependency as
"express": "^4.22.2" or update the version range if you intentionally want a
newer non-breaking patch/minor release, then commit the verified package.json
change; reference the "express" dependency entry in package.json when making the
update or leaving it as-is.
| "@guolao/vue-monaco-editor": "^1.5.1", | ||
| "@types/ws": "^8.5.4", | ||
| "axios": "^1.5.0", | ||
| "axios": "^1.17.0", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Verify axios and ws versions exist and check for security advisories
echo "=== Checking axios latest version and advisories ==="
curl -s https://registry.npmjs.org/axios | jq '.["dist-tags"].latest, .versions | keys | map(select(startswith("1.17"))) | .[]' | head -5
echo -e "\n=== Checking ws latest version and advisories ==="
curl -s https://registry.npmjs.org/ws | jq '.["dist-tags"].latest, .versions | keys | map(select(startswith("8.21"))) | .[]' | head -5
echo -e "\n=== Checking for security advisories ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 10, ecosystem: NPM, package: "axios") {
nodes {
advisory {
summary
severity
publishedAt
}
vulnerableVersionRange
firstPatchedVersion {
identifier
}
}
}
}'
gh api graphql -f query='
{
securityVulnerabilities(first: 10, ecosystem: NPM, package: "ws") {
nodes {
advisory {
summary
severity
publishedAt
}
vulnerableVersionRange
firstPatchedVersion {
identifier
}
}
}
}'Repository: farm-fe/farm
Length of output: 5331
🏁 Script executed:
#!/bin/bash
set -euo pipefail
check_version_exists() {
pkg="$1"
ver="$2"
echo "=== npm registry: $pkg@$ver exists? ==="
curl -s "https://registry.npmjs.org/${pkg}" | jq -r --arg ver "$ver" '
if .versions[$ver] != null then "yes" else "no" end
'
}
show_latest() {
pkg="$1"
echo "=== npm registry: $pkg latest dist-tag ==="
curl -s "https://registry.npmjs.org/${pkg}" | jq -r '.["dist-tags"].latest'
}
check_version_exists "axios" "1.17.0"
check_version_exists "ws" "8.21.0"
show_latest "axios"
show_latest "ws"
echo -e "\n=== GH advisory coverage for axios (first 100) ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 100, ecosystem: NPM, package: $pkg) {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}' -f pkg="axios" | jq -c '.data.securityVulnerabilities.nodes[]' | head -n 50
echo -e "\n=== GH advisory coverage for ws (first 100) ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 100, ecosystem: NPM, package: $pkg) {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}' -f pkg="ws" | jq -c '.data.securityVulnerabilities.nodes[]' | head -n 50
echo -e "\n=== GH advisory firstPatchedVersion identifiers for axios ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 100, ecosystem: NPM, package: "axios") {
nodes { firstPatchedVersion { identifier } }
}
}' | jq -r '.data.securityVulnerabilities.nodes[].firstPatchedVersion.identifier' | sort -u
echo -e "\n=== GH advisory firstPatchedVersion identifiers for ws ==="
gh api graphql -f query='
{
securityVulnerabilities(first: 100, ecosystem: NPM, package: "ws") {
nodes { firstPatchedVersion { identifier } }
}
}' | jq -r '.data.securityVulnerabilities.nodes[].firstPatchedVersion.identifier' | sort -uRepository: farm-fe/farm
Length of output: 436
🏁 Script executed:
#!/bin/bash
set -euo pipefail
node -v >/dev/null 2>&1 || true
# Install semver tooling for accurate range checks
python3 - <<'PY'
import sys, subprocess, pkgutil
pkg='semantic_version'
if pkgutil.find_loader(pkg) is None:
subprocess.check_call([sys.executable,'-m','pip','-q','install',pkg])
PY
python3 - <<'PY'
from semantic_version import Version, SimpleSpec
import json, subprocess, os, textwrap
def gh_advisories(pkg, first=200):
# Use fixed query strings to avoid variable scoping issues
query=f'''
{{
securityVulnerabilities(first: {first}, ecosystem: NPM, package: "{pkg}") {{
nodes {{
advisory {{ summary severity publishedAt }}
vulnerableVersionRange
firstPatchedVersion {{ identifier }}
}}
}}
}}
'''
out = subprocess.check_output(['gh','api','graphql','-f', 'query='+query], text=True)
data=json.loads(out)
return data['data']['securityVulnerabilities']['nodes']
def covers(ver_str, range_str):
# If range can't be parsed, treat as "unknown" (do not match)
try:
v = Version(ver_str)
spec = SimpleSpec(range_str.replace('=', '==').replace('>==','>=').replace('<==','<=').strip())
return v in spec
except Exception:
return False
targets = {
'axios': '1.17.0',
'ws': '8.21.0'
}
for pkg, target in targets.items():
nodes = gh_advisories(pkg)
matches=[]
for n in nodes:
vr = n.get('vulnerableVersionRange')
if vr and covers(target, vr):
matches.append({
'summary': (n['advisory'] or {}).get('summary'),
'severity': (n['advisory'] or {}).get('severity'),
'publishedAt': (n['advisory'] or {}).get('publishedAt'),
'vulnerableVersionRange': vr,
'firstPatchedVersion': (n.get('firstPatchedVersion') or {}).get('identifier')
})
print(f"=== {pkg}@{target} vulnerable matches from GH (0 => none) ===")
if matches:
for m in matches[:30]:
print(json.dumps(m, ensure_ascii=False))
if len(matches) > 30:
print(f"... and {len(matches)-30} more")
else:
print("NONE")
PYRepository: farm-fe/farm
Length of output: 992
🏁 Script executed:
#!/bin/bash
set -euo pipefail
node - <<'NODE'
(async () => {
// Ensure semver is available
try { require.resolve('semver'); } catch {
console.log('Installing semver...');
const { execSync } = require('child_process');
execSync('npm i --silent semver@7', { stdio: 'inherit' });
}
const semver = require('semver');
function normalizeRange(r) {
if (!r || typeof r !== 'string') return null;
// GH sometimes uses comma-separated constraints; semver supports spaces.
return r.replace(/,\s*/g, ' ').trim();
}
function rangeSat(target, r) {
const nr = normalizeRange(r);
if (!nr) return false;
// Validate range; if invalid, treat as non-match (conservative).
const vr = semver.validRange(nr);
if (!vr) return false;
return semver.satisfies(target, vr, { includePrerelease: true });
}
async function fetchAdvisories(pkg, first=100) {
const query = `
{
securityVulnerabilities(first: ${first}, ecosystem: NPM, package: "${pkg}") {
nodes {
advisory { summary severity publishedAt }
vulnerableVersionRange
firstPatchedVersion { identifier }
}
}
}`;
const out = require('child_process').execSync(
`gh api graphql -f query='${query.replace(/\n/g,' ').replace(/'/g,"\\'")}'`,
{ encoding: 'utf8', stdio: ['ignore', 'pipe', 'pipe'] }
);
const data = JSON.parse(out);
return data.data.securityVulnerabilities.nodes || [];
}
const targets = { axios: '1.17.0', ws: '8.21.0' };
for (const [pkg, target] of Object.entries(targets)) {
console.log(`\n=== ${pkg}@${target} vulnerable matches (GH) ===`);
const nodes = await fetchAdvisories(pkg, 100);
let matches = [];
for (const n of nodes) {
const vr = n.vulnerableVersionRange;
if (rangeSat(target, vr)) {
matches.push({
summary: n.advisory?.summary,
severity: n.advisory?.severity,
publishedAt: n.advisory?.publishedAt,
vulnerableVersionRange: vr,
firstPatchedVersion: n.firstPatchedVersion?.identifier
});
}
}
if (matches.length === 0) {
console.log('NONE');
} else {
for (const m of matches.slice(0, 40)) console.log(JSON.stringify(m));
if (matches.length > 40) console.log(`... and ${matches.length - 40} more`);
}
console.log(`Total GH nodes returned: ${nodes.length}`);
}
})();
NODERepository: farm-fe/farm
Length of output: 778
🏁 Script executed:
#!/bin/bash
set -euo pipefail
python3 - <<'PY'
import json, re, subprocess
from functools import lru_cache
def gh_advisories(pkg, first=100):
query = f"""
{{
securityVulnerabilities(first: {first}, ecosystem: NPM, package: "{pkg}") {{
nodes {{
advisory {{ summary severity publishedAt }}
vulnerableVersionRange
firstPatchedVersion {{ identifier }}
}}
}}
}}
"""
# Use gh directly to avoid jq variability
cmd = ["gh","api","graphql","-f", f"query={query}"]
out = subprocess.check_output(cmd, text=True)
data = json.loads(out)
return data["data"]["securityVulnerabilities"]["nodes"] or []
def parse_version(v):
# Handle plain x.y.z only (sufficient for the ranges we got)
m = re.match(r'^\s*(\d+)\.(\d+)\.(\d+)', v or "")
if not m:
return None
return tuple(map(int, m.groups()))
def cmp(a, op, b):
if op == ">": return a > b
if op == ">=": return a >= b
if op == "<": return a < b
if op == "<=": return a <= b
if op in ("=","=="): return a == b
return False
def sat_conj(target, conj):
# conj: list of comparator strings like '>= 8.0.0' or '< 8.20.1'
for op, ver in conj:
tv = parse_version(ver)
if tv is None:
return False
if not cmp(target, op, tv):
return False
return True
def parse_and_eval(target_str, vr_str):
"""
Evaluate strings like:
">= 8.0.0, < 8.20.1"
"<= 0.31.1"
">= 1.0.0, < 1.16.0"
Supports '||' by treating it as OR between groups.
"""
if not vr_str or not isinstance(vr_str, str):
return False
target = parse_version(target_str)
if target is None:
return False
# Split OR groups
or_groups = [g.strip() for g in vr_str.split("||")]
# Comparator regex: >= x.y.z, <= x.y.z, > x.y.z, < x.y.z, = x.y.z
comp_re = re.compile(r'(<=|>=|<|>|=|==)\s*([0-9]+\.[0-9]+\.[0-9]+)', re.I)
for group in or_groups:
# Split on commas for AND
parts = [p.strip() for p in group.split(",") if p.strip()]
conj = []
ok = True
for p in parts:
m = comp_re.search(p)
if not m:
ok = False
break
op, ver = m.group(1), m.group(2)
conj.append((op if op != "==" else "=", ver))
if ok and conj and sat_conj(target, conj):
return True
return False
targets = {"axios": "1.17.0", "ws": "8.21.0"}
for pkg, tv in targets.items():
nodes = gh_advisories(pkg, first=100)
matches = []
for n in nodes:
vr = n.get("vulnerableVersionRange")
if parse_and_eval(tv, vr):
matches.append({
"summary": (n.get("advisory") or {}).get("summary"),
"severity": (n.get("advisory") or {}).get("severity"),
"publishedAt": (n.get("advisory") or {}).get("publishedAt"),
"vulnerableVersionRange": vr,
"firstPatchedVersion": (n.get("firstPatchedVersion") or {}).get("identifier"),
})
print(f"\n=== {pkg}@{tv} matches within GH vulnerableVersionRange (first 100 nodes) ===")
print(f"GH nodes returned: {len(nodes)}")
if not matches:
print("NONE")
else:
print(f"Matches: {len(matches)} (showing up to 20)")
for m in matches[:20]:
print(json.dumps(m, ensure_ascii=False))
PYRepository: farm-fe/farm
Length of output: 269
Confirm axios@^1.17.0 and ws@^8.21.0 are valid and patched for security advisories
axios@1.17.0andws@8.21.0exist on the npm registry (both are the currentlatestdist-tags).- GitHub SecurityVulnerabilities entries returned (up to the first 100 results) have
vulnerableVersionRangevalues that do not include1.17.0or8.21.0, indicating the reported advisories should be resolved. - Still verify no breaking/behavioral changes for the actual installed versions (lockfile update + running existing tests / checking changelogs).
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@js-plugins/visualizer/package.json` at line 21, The package.json currently
pins "axios": "^1.17.0" and (implicitly) uses "ws": "^8.21.0"; confirm these
exact versions are safe by updating the lockfile (run npm/yarn/pnpm install to
regenerate lockfile), run the full test suite and any integration steps to
ensure no behavioral or breaking changes, and cross-check changelogs/release
notes for axios and ws for breaking changes; if any security advisories still
apply or tests fail, update the dependency versions in package.json to the
minimally safe patched releases and regenerate the lockfile, then re-run tests
to validate.
| "@jridgewell/trace-mapping": "^0.3.17", | ||
| "@types/less": "^3.0.3", | ||
| "@types/node": "^18.19.67", | ||
| "@types/node": "^24.10.4", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Check project's Node.js version requirements
echo "=== Checking package.json engines field ==="
fd -t f '^package\.json$' -x jq -r 'select(.engines.node != null) | "\(.name // "root"): \(.engines.node)"' {} \;
echo -e "\n=== Checking .nvmrc or .node-version ==="
if [ -f .nvmrc ]; then
echo ".nvmrc: $(cat .nvmrc)"
fi
if [ -f .node-version ]; then
echo ".node-version: $(cat .node-version)"
fi
echo -e "\n=== Checking GitHub Actions Node.js versions ==="
fd -t f '^.*\.ya?ml$' .github/workflows -x grep -H 'node-version' {} \;
echo -e "\n=== Verifying `@types/node`@24.10.4 exists ==="
curl -s https://registry.npmjs.org/@types/node | jq '.versions["24.10.4"] // "Version not found"' | head -1Repository: farm-fe/farm
Length of output: 2384
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Inspect js-plugins/vue/package.json engines & deps ==="
cat js-plugins/vue/package.json | sed -n '1,120p'
echo -e "\n=== Extract `@types/node` version in js-plugins/vue/package.json ==="
rg -n "\"`@types/node`\"" js-plugins/vue/package.json
echo -e "\n=== Find tsconfig files and node/type settings ==="
fd -t f "tsconfig*.json" . -E node_modules -E dist -E build | head -n 200 | sed 's|^\./||'
# Show relevant compiler options for configs that likely exist
for f in $(fd -t f "tsconfig*.json" . -E node_modules -E dist -E build); do
if rg -q '"types"' "$f" || rg -q 'lib' "$f" || rg -q 'target' "$f" || rg -q 'moduleResolution' "$f"; then
echo -e "\n--- $f (key compilerOptions) ---"
rg -n --max-count=80 '\"compilerOptions\"|\"types\"|\"target\"|\"lib\"|\"moduleResolution\"|\"types\"' "$f" || true
fi
done
echo -e "\n=== Check `@types/node`@24.10.4 resolves (npm registry) ==="
node -e "require('https').get('https://registry.npmjs.org/@types/node/24.10.4',res=>{console.log('status',res.statusCode);}).on('error',e=>{console.error(e.message); process.exit(1);});"Repository: farm-fe/farm
Length of output: 142
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== js-plugins/vue/package.json engines (if any) + `@types/node` line ==="
cat js-plugins/vue/package.json | sed -n '1,140p'
rg -n "\"`@types/node`\"|\"engines\"|\"typescript\"|\"typeRoots\"|\"types\"" js-plugins/vue/package.json || true
echo -e "\n=== tsconfig* within js-plugins/vue ==="
fd -t f "tsconfig*.json" js-plugins/vue -E node_modules -E dist -E build | sed 's|^\./||' | head -n 50
for f in $(fd -t f "tsconfig*.json" js-plugins/vue -E node_modules -E dist -E build); do
echo -e "\n--- $f (relevant compilerOptions) ---"
rg -n '"compilerOptions"|' "$f" || true
rg -n '"types"\s*:|typeRoots|lib|target|moduleResolution|module|' "$f" || true
done
echo -e "\n=== Does js-plugins/vue reference `@types/node` anywhere else? ==="
rg -n "`@types/node`" js-plugins/vue || trueRepository: farm-fe/farm
Length of output: 2875
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== tsconfig.base.json ==="
cat tsconfig.base.json | sed -n '1,220p'
echo -e "\n=== Search for compilerOptions.types / typeRoots / lib / target in base ==="
rg -n '"types"\s*:|typeRoots|\"lib\"|\"target\"|moduleResolution|types' tsconfig.base.json
echo -e "\n=== Any Node type inclusion in vue plugin tsconfig.json (effective via extends?) ==="
cat js-plugins/vue/tsconfig.json | sed -n '1,120p'Repository: farm-fe/farm
Length of output: 796
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== tsconfig.base.json (relevant compilerOptions) ==="
rg -n '"(types|typeRoots|lib|target|moduleResolution|module)"\s*:' tsconfig.base.json || true
cat tsconfig.base.json | sed -n '1,120p'
echo -e "\n=== tsconfig* in js-plugins/vue ==="
fd -t f "tsconfig*.json" js-plugins/vue -E node_modules -E dist -E build | sed 's|^\./||'
for f in $(fd -t f "tsconfig*.json" js-plugins/vue -E node_modules -E dist -E build); do
echo -e "\n--- $f (key compilerOptions) ---"
rg -n '"(compilerOptions|types|typeRoots|lib|target|moduleResolution|module)"\s*' "$f" || true
cat "$f" | sed -n '1,120p'
doneRepository: farm-fe/farm
Length of output: 1098
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== js-plugins/vue: Node built-in imports/usages in src (quick scan) ==="
rg -n 'from "node:|require\("node:|node:fs|node:crypto|node:timers|process\.' js-plugins/vue/src js-plugins/vue/farm.config.ts js-plugins/vue || true
echo -e "\n=== Find TypeScript version used in repo ==="
# look for the first few package.json occurrences of typescript
rg -n '"typescript"\s*:' -S --glob 'package.json' . | head -n 30 || true
echo -e "\n=== Check js-plugins/vue tsc config/output scripts ==="
cat js-plugins/vue/package.json | sed -n '1,120p'Repository: farm-fe/farm
Length of output: 4562
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Root package.json engines + devDependency typescript ==="
node -e "const p=require('./package.json'); console.log('engines:', p.engines?.node); console.log('typescript:', p.devDependencies?.typescript || p.dependencies?.typescript)" || true
echo -e "\n=== CI node-version (workflows) ==="
rg -n "node-version:\s*'?(18|18\.|18x|>=18|18\.x)" .github/workflows -S || true
rg -n "node-version:" .github/workflows -S || true
echo -e "\n=== Find all `@types/node` occurrences (package.json) ==="
rg -n '"`@types/node`"\s*:' -S --glob '**/package.json' . | head -n 50 || true
echo -e "\n=== Find whether js-plugins/vue has typescript in its own deps (it shouldn't) ==="
cat js-plugins/vue/package.json | rg -n '"typescript"\s*:' || trueRepository: farm-fe/farm
Length of output: 1985
🌐 Web query:
@types/node@24.10.4 typescript version requirement peerDependencies
💡 Result:
The package @types/node version 24.10.4 does not have any peerDependencies defined [1][2]. It only lists undici-types as a dependency [2]. There is no formal TypeScript version requirement defined in the package's metadata as a peerDependency [1][2]. DefinitelyTyped packages, including @types/node, generally do not enforce specific TypeScript versions via peerDependencies [3]. While TypeScript version compatibility is important, it is typically managed by the user's project configuration and the inherent compatibility of the type definitions themselves rather than package manager-enforced peer dependencies [3][4]. Regarding versioning, the major and minor versions of @types/node are intended to correspond to the major and minor versions of the Node.js runtime they support [5]. The package itself is a collection of type definitions and does not impose restrictive peer dependency requirements on the host TypeScript environment [1][3].
Citations:
- 1: https://shoulder.dev/npm/@types/node/24.10.4
- 2: firezone/firezone@a895513
- 3: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/04d84e0d1780cd5c2be487bd6e02a6a00f434769
- 4: Suggestion: change @types/node dependencies to devDependencies DefinitelyTyped/DefinitelyTyped#55519
- 5: https://stackoverflow.com/questions/42035263/relationship-between-the-version-of-node-js-and-the-version-of-types-node
🌐 Web query:
@types/node 24.10.4 TypeScript minimum version support
💡 Result:
The @types/node package version 24.10.4 supports TypeScript 5.8 and later [1]. While @types/node does not always strictly enforce a single minimum TypeScript version for every minor update, the definitions for the Node 24.x line generally target modern TypeScript features to ensure compatibility with Node.js APIs [1][2]. Definitions in the DefinitelyTyped repository for recent versions of @types/node explicitly note support for TypeScript 5.8+ [1]. If you are using a significantly older version of TypeScript, you may encounter type errors due to the use of newer TS language features or library definitions (such as updated lib references) within the @types/node package [1]. It is recommended to use the version of TypeScript specified in the package's configuration or a more recent one to ensure full compatibility [1].
Citations:
- 1: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/node/index.d.ts
- 2: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node
Align @types/node with the workspace Node.js + TypeScript versions
- CI/workspace targets Node 18 (
engines.node: >=18, GitHub workflowsnode-version: 18), butjs-plugins/vue/package.jsonupgrades@types/nodeto^24.10.4. @types/node@24.10.4is intended for TypeScript 5.8+; the repo root uses TypeScript^4.9.4, so thejs-plugins/vuetscbuild is likely to hit type/TS feature incompatibilities (especially sincetsconfigdoesn’t constrain includedtypes).
Update either the TypeScript version used for this build (to 5.8+) or pin @types/node to a version compatible with the currently used TypeScript.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@js-plugins/vue/package.json` at line 46, The package dependency "`@types/node`"
in js-plugins/vue package.json is set to ^24.10.4 which targets TS 5.8+ and will
conflict with the workspace TypeScript (^4.9.4); either pin "`@types/node`" to a
Node 18 / TS 4.9–compatible release (e.g. an 18.x `@types/node`) in package.json,
OR upgrade the package's TypeScript devDependency (and tsconfig if needed) to
>=5.8 so `@types/node`@24 is supported; update the dependency entry for
"`@types/node`" or bump the package's TypeScript version accordingly and run the
package install/build to verify no type errors.
| "@biomejs/biome": "1.8.3", | ||
| "@changesets/cli": "^2.26.0", | ||
| "@codspeed/vitest-plugin": "^3.1.1", | ||
| "@codspeed/vitest-plugin": "^5.5.0", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Verify the upgraded dependency versions exist and check for breaking changes
echo "=== Checking vitest versions ==="
npm view vitest@4.1.8 version 2>/dev/null || echo "vitest@4.1.8 not found"
npm view `@vitest/coverage-v8`@4.1.8 version 2>/dev/null || echo "`@vitest/coverage-v8`@4.1.8 not found"
echo -e "\n=== Checking vite version ==="
npm view vite@6.4.2 version 2>/dev/null || echo "vite@6.4.2 not found"
echo -e "\n=== Checking `@codspeed/vitest-plugin` version ==="
npm view `@codspeed/vitest-plugin`@5.5.0 version 2>/dev/null || echo "`@codspeed/vitest-plugin`@5.5.0 not found"
echo -e "\n=== Checking `@types/node` version ==="
npm view `@types/node`@24.10.4 version 2>/dev/null || echo "`@types/node`@24.10.4 not found"
echo -e "\n=== Checking rollup version ==="
npm view rollup@3.30.0 version 2>/dev/null || echo "rollup@3.30.0 not found"
echo -e "\n=== Searching for vitest.config files that may need updates ==="
fd -e ts -e js 'vitest.config' -x echo "Found config: {}"
echo -e "\n=== Checking for vitest imports in test files ==="
rg -l "from ['\"]vitest['\"]" --type ts --type js -g '!node_modules' | head -10Repository: farm-fe/farm
Length of output: 827
🌐 Web query:
vitest 4.0 breaking changes migration guide
💡 Result:
Vitest 4.0 was released on October 22, 2025 [1][2][3]. Because it is a major release, it includes several breaking changes that require updates to your configuration and test code [3][4]. Key Migration Requirements and Breaking Changes: Prerequisites Vitest 4.0 requires Node.js >= 20.0.0 and Vite >= 6.0.0 [4][5]. Ensure your environment meets these requirements before upgrading [4]. Browser Mode Browser mode is now stable and requires a provider factory [2]. You must now install and import a separate provider package (@vitest/browser-playwright, @vitest/browser-webdriverio, or @vitest/browser-preview) instead of passing a string to the provider option [2][6][7]. Mocking Changes - vi.fn.getMockName now returns [MockFunction] by default, rather than [MockFunction spy] [4]. - vi.restoreAllMocks now only restores mocks manually created with vi.spyOn; automocks are no longer affected [4]. - Automocked getters now return undefined by default instead of calling the original getter [4]. - Mocks called with the new keyword now correctly construct instances; mock implementations must use the function or class keyword to ensure compatibility [5][7]. Code Coverage - coverage.ignoreEmptyLines and coverage.experimentalAstAwareRemapping have been removed [4][5]. - coverage.all has been removed, and Vitest now defaults to including only covered files in reports [5][7]. It is recommended to explicitly define coverage.include in your configuration [5][7]. API and Configuration Removals - Many deprecated APIs and internal helpers were removed, including the basic reporter, minWorkers (now handled automatically), and support for Vite 5 [1][6]. - workspace has been replaced by projects [6][7]. - Node types must now be imported from vitest/node rather than the main entry point [1][6]. For the complete list of breaking changes and specific migration steps, refer to the official Vitest Migration Guide at https://vitest.dev/guide/migration.html [4].
Citations:
- 1: https://github.com/vitest-dev/vitest/releases/tag/v4.0.0
- 2: https://vitest.dev/blog/vitest-4
- 3: https://voidzero.dev/posts/announcing-vitest-4
- 4: https://vitest.dev/guide/migration.html
- 5: https://github.com/vitest-dev/vitest/blob/main/docs/guide/migration.md
- 6: https://newreleases.io/project/npm/vitest/release/4.0.0
- 7: https://github.com/vitest-dev/vitest/blob/1a4705da/docs/guide/migration.md
🌐 Web query:
vite 6.0 breaking changes migration guide
💡 Result:
Vite 6.0 introduces several breaking changes that require attention during migration. The official Vite 6 migration guide is the primary resource for these updates [1]. Key breaking changes and migration steps include: Environment API and Module Runner: Vite 6 introduces the new experimental Environment API [1][2]. The previously experimental Vite Runtime API (introduced in Vite 5.1) has been removed and replaced by the Module Runner API; users of the former must migrate to the latter [1]. CSS and Preprocessors: - Sass: The default API for Sass has changed to the modern/modern-compiler API [2]. If your project relies on the legacy API, you can revert to it by setting css.preprocessorOptions.sass.api: 'legacy' (or scss), though this legacy support is scheduled for removal in Vite 7 [1]. - CSS File Naming: When building libraries, the default output file name now uses the package name from package.json [1]. You can explicitly control this with the new build.lib.cssFileName option [1]. JSON Handling: - Stringify: The default for json.stringify is now 'auto', which only stringifies large JSON files [1]. You can disable this by setting the option to false, or keep the previous behavior by adjusting other related settings [1]. - Named Exports: json.namedExports is no longer disabled even when json.stringify is set to true; if you need the old behavior, you must explicitly set json.namedExports: false [1]. Other Key Breaking Changes: - Dependency and Environment Requirements: Vite 6 drops support for Node.js 21 and updates several core dependencies, including switching to chokidar v4 and tinyglobby (replacing fast-glob) [2][3]. - PostCSS: PostCSS configuration is now loaded only within the workspace root [2]. - SSR Minification: build.cssMinify now defaults to 'esbuild' for SSR builds [2]. - FS/Config: The fs.cachedChecks option has been removed [2]. - Security: Subsequent updates (specifically in 6.0.9) introduced security measures including server.allowedHosts and setting server.cors to false by default [4]. For a complete and step-by-step migration process, always refer to the official migration guide at v6.vite.dev/guide/migration [1].
Citations:
- 1: https://v6.vite.dev/guide/migration
- 2: https://github.com/vitejs/vite/blob/v6.0.1/packages/vite/CHANGELOG.md
- 3: https://github.com/vitejs/vite/blob/v6.0.6/packages/vite/CHANGELOG.md
- 4: https://github.com/vitejs/vite/blob/v6.0.9/packages/vite/CHANGELOG.md
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Read package.json engines (if any) ==="
node -e "const p=require('./package.json'); console.log(p.engines||'no engines field')" 2>/dev/null || true
echo -e "\n=== Inspect vitest config files ==="
ls -1 ./vitest.config*.ts ./vitest.config*.mts ./vitest.config*.js ./vitest.config*.mjs 2>/dev/null || true
for f in $(ls -1 ./vitest.config*.ts 2>/dev/null); do
echo -e "\n--- $f (head) ---"
head -n 120 "$f"
done
echo -e "\n=== Search for known Vitest 4 breaking-change config options/usages ==="
rg -n --hidden --no-ignore-vcs \
"coverage\.ignoreEmptyLines|coverage\.experimentalAstAwareRemapping|coverage\.all|minWorkers|workspace\s*:" \
. || true
echo -e "\n=== Search for vitest provider usage that changed in Vitest 4 ==="
rg -n --hidden --no-ignore-vcs \
"provider\s*:\s*['\"][^'\"]+['\"]|browser-playwright|browser-webdriverio|browser-preview" \
. || true
echo -e "\n=== Search for deprecated vitest node types import ==="
rg -n --hidden --no-ignore-vcs \
"from ['\"]vitest['\"]|vitest/node|`@types/node`" \
. || true
echo -e "\n=== Check Vitest imports in test/code for direct 'vitest' usage ==="
rg -n "from ['\"]vitest['\"]" --type ts --type js -g '!node_modules' || trueRepository: farm-fe/farm
Length of output: 50368
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== CI Node versions (common locations) ==="
rg -n --hidden --no-ignore-vcs \
"node-version:|setup-node|NODE_VERSION" .github package.json pnpm-workspace.yaml . 2>/dev/null || true
echo -e "\n=== vitest/node type import usage ==="
rg -n --hidden --no-ignore-vcs \
"from ['\"]vitest/node['\"]|vitest/node" . --glob '!node_modules/**' || true
echo -e "\n=== Vitest 4 migration-impacting config options (only vitest configs) ==="
rg -n \
"coverage\.ignoreEmptyLines|coverage\.experimentalAstAwareRemapping|coverage\.all|minWorkers|workspace\s*:" \
./vitest.config*.ts ./vitest.config*.js ./vitest.config*.mjs ./vitest.config*.cjs 2>/dev/null || true
echo -e "\n=== provider option usage inside vitest-related configs ==="
rg -n \
"provider\s*:\s*['\"][^'\"]+['\"]" \
. --glob '!node_modules/**' --glob '*vitest*' --glob '*config*' || true
echo -e "\n=== Vitest coverage config presence ==="
rg -n "coverage\s*:" ./vitest.config*.ts ./vitest.config*.js 2>/dev/null || true
echo -e "\n=== package.json test/build scripts ==="
node -e "const p=require('./package.json'); console.log({scripts:p.scripts||{}})" 2>/dev/null || trueRepository: farm-fe/farm
Length of output: 4562
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== npm engines for upgraded deps ==="
npm view vitest@4.1.8 engines --json 2>/dev/null || echo "vitest engines not found"
npm view vite@6.4.2 engines --json 2>/dev/null || echo "vite engines not found"
npm view `@vitest/coverage-v8`@4.1.8 engines --json 2>/dev/null || echo "`@vitest/coverage-v8` engines not found"
npm view `@codspeed/vitest-plugin`@5.5.0 engines --json 2>/dev/null || echo "`@codspeed/vitest-plugin` engines not found"
npm view `@types/node`@24.10.4 engines --json 2>/dev/null || echo "`@types/node` engines not found"Repository: farm-fe/farm
Length of output: 188
🏁 Script executed:
#!/bin/bash
set -u
echo "=== npm engines (labeled) ==="
for spec in \
"vitest@4.1.8" \
"vite@6.4.2" \
"`@vitest/coverage-v8`@4.1.8" \
"`@codspeed/vitest-plugin`@5.5.0" \
"`@types/node`@24.10.4"
do
echo "--- $spec ---"
npm view "$spec" engines --json 2>/dev/null || echo "(engines not found)"
done
echo -e "\n=== CI workflows that run vitest ==="
rg -n --hidden --no-ignore-vcs "vitest\s(run|--|\\b)|test-e2e|vitest run" .github/workflows package.json pnpm-workspace.yaml 2>/dev/null || true
echo -e "\n=== Show node setup steps in .github/workflows/ci.yaml (near node-version) ==="
rg -n "setup-node|node-version" .github/workflows/ci.yaml 2>/dev/null || trueRepository: farm-fe/farm
Length of output: 992
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== ci.yaml around vitest e2e step ==="
sed -n '40,95p' .github/workflows/ci.yaml
echo -e "\n=== ci.yaml around vitest bench step ==="
sed -n '210,270p' .github/workflows/ci.yaml
echo -e "\n=== ci.yaml around each setup-node@v3 occurrence ==="
for ln in 33 96 130 218; do
echo -e "\n--- lines ${ln}±15 ---"
sed -n "$((ln-15)),$((ln+25))p" .github/workflows/ci.yaml
done
echo -e "\n=== npm view: engines for `@vitest/coverage-v8` and `@codspeed/vitest-plugin` (raw) ==="
npm view `@vitest/coverage-v8`@4.1.8 engines --json 2>/dev/null || echo "(no engines field)"
npm view `@codspeed/vitest-plugin`@5.5.0 engines --json 2>/dev/null || echo "(no engines field)"
echo -e "\n=== npm view: engines for vitest@4.1.8 already printed above; showing version/engines again ==="
npm view vitest@4.1.8 engines --json 2>/dev/null || trueRepository: farm-fe/farm
Length of output: 10252
Update CI Node to run Vitest 4 (Vitest now requires Node >=20).
vitest@4.1.8(and the corresponding@vitest/coverage-v8@4.1.8) exists, but itsengines.nodeis^20.0.0 || ^22.0.0 || >=24.0.0, while.github/workflows/ci.yamlusesactions/setup-nodewithnode-version: 18fornpm run test-e2e,npm run test, andvitest bench.vitest.config*.{ts,js}doesn’t reference the commonly removed Vitest coverage/minWorkers options, and the code already usesvitest/nodetypes (e2e/vitestGlobalSetup.ts).- Fix: bump CI Node (and likely
package.jsonengines) to >=20, then run the fullpnpm test+pnpm test-e2e.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@package.json` at line 29, CI is still using Node 18 but Vitest 4 requires
Node >=20; update .github/workflows/ci.yaml to set actions/setup-node
node-version to 20 (or 22) for the jobs running npm run test, npm run test-e2e
and vitest bench, and update package.json "engines.node" to "^20.0.0 || ^22.0.0
|| >=24.0.0" to match vitest@4.1.8/@vitest/coverage-v8; after making these
changes run the full test matrix (pnpm test and pnpm test-e2e) and fix any
runtime failures reported by vitest.
Description:
BREAKING CHANGE:
Related issue (if exists):
Summary by CodeRabbit