Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
97 changes: 79 additions & 18 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion sri-plugin/examples/hwp-custom-template/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"private": true,
"devDependencies": {
"css-loader": "^7.1.4",
"css-select": "^5.2.2",
"css-select": "^7.0.0",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check Node.js version specifications across the repository

echo "=== Checking for Node.js version specifications ==="

# Check for .nvmrc files
echo -e "\n--- .nvmrc files ---"
fd -t f '^\.nvmrc$' --exec cat {}

# Check for .node-version files
echo -e "\n--- .node-version files ---"
fd -t f '^\.node-version$' --exec cat {}

# Check package.json engines fields
echo -e "\n--- package.json engines fields ---"
fd -t f '^package\.json$' --exec sh -c 'echo "File: {}" && cat {} | jq -r ".engines // empty"'

# Check CI configuration for Node.js versions
echo -e "\n--- GitHub Actions workflows ---"
fd -t f -e yml -e yaml . .github/workflows --exec sh -c 'echo "File: {}" && rg -A 2 "node-version" {}'

# Check for volta configuration
echo -e "\n--- Volta configuration in root package.json ---"
cat package.json 2>/dev/null | jq -r '.volta // empty'

Repository: rstackjs/rspack-plugin-ci

Length of output: 3245


🌐 Web query:

css-select 7.0.0 minimum Node.js version 20.19.0 engines

💡 Result:

The minimum required Node.js version for css-select version 7.0.0 is 20.19.0 [1][2]. This requirement was established as part of a release that transitioned the package to be ESM-only [1][2].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== test.yml node matrix ==="
if [ -f .github/workflows/test.yml ]; then
  sed -n '1,200p' .github/workflows/test.yml | rg -n "matrix|node-version" -n || true
  sed -n '1,260p' .github/workflows/test.yml | sed -n '1,260p' | rg -n "matrix:|node:|node-version" || true
  # Print a smaller focused region around matrix if present
  rg -n "matrix" .github/workflows/test.yml -n
  rg -n "node-version" .github/workflows/test.yml -n
fi

echo
echo "=== lint.yml node-version ==="
if [ -f .github/workflows/lint.yml ]; then
  rg -n "node-version" .github/workflows/lint.yml -n
  sed -n '1,120p' .github/workflows/lint.yml | rg -n "node-version" -n || true
fi

echo
echo "=== hwp-custom-template package.json (relevant engines/deps) ==="
cat sri-plugin/examples/hwp-custom-template/package.json | sed -n '1,120p'

Repository: rstackjs/rspack-plugin-ci

Length of output: 1296


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== other workflow node-version occurrences ==="
rg -n "node-version" .github/workflows || true

echo
echo "=== look for mentions of Node 20/requirements in repo docs ==="
rg -n "Node\.?js|node version|20\.19|20\.|engines" -S . || true

echo
echo "=== check root package.json for volta/engines (if any) ==="
cat package.json 2>/dev/null | jq -r '"engines=" + (.engines|tostring) + "\nvolta=" + (.volta|tostring)' 2>/dev/null || true

Repository: rstackjs/rspack-plugin-ci

Length of output: 50382


🏁 Script executed:

#!/bin/bash
set -euo pipefail
cat -n package.json | sed -n '1,80p'

Repository: rstackjs/rspack-plugin-ci

Length of output: 1808


Document/enforce Node.js requirement for css-select v7 (>=20.19.0)

css-select@7.0.0 requires Node.js >= 20.19.0. The example sri-plugin/examples/hwp-custom-template/package.json doesn’t declare an engines.node constraint (and the repo root package.json only pins pnpm), so running the example with an older Node can fail even though CI runs Node 22.x (.github/workflows/test.yml, .github/workflows/lint.yml). Add engines: { "node": ">=20.19.0" } to the example (and/or root) to make the requirement explicit.

🤖 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 `@sri-plugin/examples/hwp-custom-template/package.json` at line 9, Add an
explicit Node engine requirement to the example package.json to match
css-select@7.0.0’s minimum Node version: update the package.json in the
hwp-custom-template example to include an "engines" field with "node":
">=20.19.0" so the runtime requirement is enforced (reference the package.json
in the example and the dependency "css-select": "^7.0.0"); ensure the field is
valid JSON and consider mirroring this constraint in the repo root package.json
if you want to enforce it project-wide.

"expect": "^26.6.2",
"html-webpack-plugin": "^5.6.7",
"htmlparser2": "^8.0.2",
Expand Down
2 changes: 1 addition & 1 deletion sri-plugin/examples/hwp-externals/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"license": "MIT",
"private": true,
"devDependencies": {
"css-select": "^5.2.2",
"css-select": "^7.0.0",
"expect": "^26.6.2",
"html-webpack-externals-plugin": "^3.8.0",
"html-webpack-plugin": "^5.6.7",
Expand Down
2 changes: 1 addition & 1 deletion sri-plugin/examples/hwp-output-parent-dir/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"license": "MIT",
"private": true,
"devDependencies": {
"css-select": "^5.2.2",
"css-select": "^7.0.0",
"expect": "^26.6.2",
"html-webpack-plugin": "^5.6.7",
"htmlparser2": "^8.0.2",
Expand Down
2 changes: 1 addition & 1 deletion sri-plugin/examples/hwp-public-path/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"license": "MIT",
"private": true,
"devDependencies": {
"css-select": "^5.2.2",
"css-select": "^7.0.0",
"expect": "^26.6.2",
"html-webpack-plugin": "^5.6.7",
"htmlparser2": "^8.0.2",
Expand Down
2 changes: 1 addition & 1 deletion sri-plugin/examples/hwp-subdirectories/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"license": "MIT",
"private": true,
"devDependencies": {
"css-select": "^5.2.2",
"css-select": "^7.0.0",
"expect": "^26.6.2",
"html-webpack-plugin": "^5.6.7",
"htmlparser2": "^8.0.2",
Expand Down