Skip to content
Merged
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
34 changes: 34 additions & 0 deletions .github/workflows/pr-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,40 @@ jobs:
- name: run format check
run: pnpm format:check

knip:
name: knip
runs-on: ubuntu-latest
needs: [setup]
steps:
- name: checkout
uses: actions/checkout@v4

- name: setup pnpm
uses: pnpm/action-setup@v4
with:
version: ${{ env.PNPM_VERSION }}

- name: setup node
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}

Comment on lines +124 to +128
Copy link

Copilot AI Mar 23, 2026

Choose a reason for hiding this comment

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

knip@6 (and its oxc-parser dependency) declares engines.node: ^20.19.0 || >=22.12.0 in the lockfile. This job uses node-version: ${{ env.NODE_VERSION }} where NODE_VERSION is currently set to "20", which doesn’t guarantee a >=20.19.0 patch level and can cause pnpm install/pnpm knip to fail on engine checks. Consider pinning NODE_VERSION to 20.19.0+ (or 22.12.0+) or overriding the node version just for this job to match the new engine requirement.

Copilot uses AI. Check for mistakes.
- name: resolve pnpm store path
id: pnpm-store
run: echo "path=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT"

- name: restore pnpm store
uses: actions/cache@v4
with:
path: ${{ steps.pnpm-store.outputs.path }}
key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml') }}

- name: install dependencies
run: pnpm install --frozen-lockfile

- name: run knip
run: pnpm knip

test:
name: test
runs-on: ubuntu-latest
Expand Down
19 changes: 11 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,22 @@
"format": "oxfmt src/",
"format:check": "oxfmt --check src/",
"test": "vitest run",
"test:watch": "vitest"
"test:watch": "vitest",
"knip": "knip"
},
"devDependencies": {
"@cloudflare/workers-types": "^4.20260307.1",
"@typescript/native-preview": "^7.0.0-dev",
"knip": "^5.86.0",
"@cloudflare/workers-types": "^4.20260317.1",
"@typescript/native-preview": "7.0.0-dev.20260323.1",
"knip": "^6.0.3",
"oxfmt": "^0.36.0",
Comment on lines +18 to 20
Copy link

Copilot AI Mar 23, 2026

Choose a reason for hiding this comment

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

PR description says knip is bumped from ^5.88.1, but package.json shows the previous specifier as ^5.86.0. If the description is meant to reflect the actual before/after, please update it (or adjust the dependency version if the intent was to start from ^5.88.1).

Copilot uses AI. Check for mistakes.
"oxlint": "^1.51.0",
"vitest": "^4.0.18",
"wrangler": "^4.71.0"
"oxlint": "^1.56.0",
"vitest": "^4.1.1",
"wrangler": "^4.76.0"
},
Copy link

Copilot AI Mar 23, 2026

Choose a reason for hiding this comment

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

After upgrading to knip@^6.0.3, the lockfile indicates a stricter Node engine requirement (^20.19.0 || >=22.12.0). To prevent local installs (and other CI workflows) from breaking on older Node 20 patch versions, consider adding a top-level engines.node in package.json that matches the new requirement (or bumping the project’s documented Node version accordingly).

Suggested change
},
},
"engines": {
"node": "^20.19.0 || >=22.12.0"
},

Copilot uses AI. Check for mistakes.
"knip": {
"ignoreDependencies": ["@typescript/native-preview"]
"ignoreDependencies": [
"@typescript/native-preview"
]
},
"packageManager": "pnpm@10.28.1"
}
Loading
Loading