chore(toolchain): align Electron 40 with Node 24#1527
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughToolchain and runtime versions were bumped across CI workflows, config, docs, and package metadata: Node pinned to 24.14.1, pnpm to 10.13.1, package.json engines tightened, dev deps updated, and multiple ACP agents in the registry advanced to newer releases. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related PRs
Poem
🚥 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)
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: 5
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.github/workflows/build.yml:
- Around line 41-44: The workflow uses pnpm/action-setup@v2 in the "Setup pnpm"
steps while FORCE_JAVASCRIPT_ACTIONS_TO_NODE24 is enabled; update those steps to
use pnpm/action-setup@v4 (or later) so the action runs on node24 runtime, and
apply the same change to all "Setup pnpm" blocks in this repo's workflow files
(build.yml, release.yml, prcheck.yml) to avoid the node16 vs node24 mismatch.
Ensure any occurrences of "pnpm/action-setup@v2" are replaced with
"pnpm/action-setup@v4" (or a later pinned version) in each workflow file.
In @.github/workflows/prcheck.yml:
- Around line 57-60: Replace usages of the GitHub Action reference
"pnpm/action-setup@v2" with "pnpm/action-setup@v5" everywhere this workflow
variable is used (all workflows that set
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true), e.g. the step that currently names
"Setup pnpm" and uses pnpm/action-setup@v2; update those occurrences in the same
steps in the other workflows to ensure the action runs on node24-compatible
runners.
In @.github/workflows/release.yml:
- Around line 136-139: Update all occurrences of the pnpm action in the release
workflow to use pnpm/action-setup@v6 (replace pnpm/action-setup@v2) so the
release jobs that force Node 24 can successfully set up pnpm; locate the action
usage lines like "uses: pnpm/action-setup@v2" in the release.yml (including the
instances around the shown diff and the other occurrences you noted) and change
them to "uses: pnpm/action-setup@v6" for each release build job.
In `@docs/guides/getting-started.md`:
- Around line 5-9: Update the prerequisite under the "## 前置要求" section to mark
Node.js 24.14.1 as required (not recommended) to match package.json's engine
range (>=24.14.1 <25); change the bullet "- Node.js `24.14.1` recommended" to a
required statement that explicitly notes the supported range (e.g., "Node.js
>=24.14.1 <25 (required)") so the docs and package.json remain consistent.
In `@package.json`:
- Line 9: The installRuntime commands calling tiny-runtime-injector with --type
node are missing an explicit runtime version; update each invocation of
tiny-runtime-injector --type node in the installRuntime:* scripts to include
--runtime-version 24.14.1 so the runtime matches the engines.node value
(24.14.1) in package.json; look for the installRuntime:* script entries that
call tiny-runtime-injector and append --runtime-version 24.14.1 to each
platform-specific --type node invocation.
🪄 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: 751663d2-31d3-4dc1-b6b5-b37169c77724
📒 Files selected for processing (8)
.github/workflows/build.yml.github/workflows/prcheck.yml.github/workflows/release.ymldocs/guides/getting-started.mdmise.tomlpackage.jsonresources/acp-registry/registry.jsonresources/model-db/providers.json
| - name: Setup pnpm | ||
| uses: pnpm/action-setup@v2 | ||
| with: | ||
| version: 10.12.1 | ||
| version: 10.13.1 |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Expect no remaining v2 pnpm setup actions after the fix.
rg -n -C2 'pnpm/action-setup@v2' .github/workflowsRepository: ThinkInAIXYZ/deepchat
Length of output: 1946
🌐 Web query:
pnpm/action-setup v2 Node 24 compatibility
💡 Result:
pnpm/action-setup v2 is not compatible with Node.js 24. The official repository explicitly warns that "The v2 version of this action has stopped working with newer Node.js versions. Please, upgrade to the latest version to fix any issues." v2 uses 'node16' in its action.yml (updated from node12 in v2.2.4), while Node 24 requires 'node24' in the runner specification, as seen in GitHub's error messages for unsupported node versions like node22. Later versions (v4+, v5.0.0) have been updated to support Node.js 24 by changing to 'using: node24' and updating dependencies like @types/node to ^22+.
Citations:
- 1: https://github.com/pnpm/action-setup
- 2: pnpm/action-setup@fc06bc1
- 3: pnpm/action-setup@v2.2.2...v2.2.4
- 4: https://github.com/pnpm/action-setup/
🏁 Script executed:
# Check the build.yml setup-node configuration and FORCE_JAVASCRIPT_ACTIONS_TO_NODE24 setting
rg -n 'setup-node|FORCE_JAVASCRIPT_ACTIONS_TO_NODE24|node-version' .github/workflows/build.yml -A 2 -B 1Repository: ThinkInAIXYZ/deepchat
Length of output: 854
🏁 Script executed:
# Check release.yml and prcheck.yml for Node 24 settings
rg -n 'FORCE_JAVASCRIPT_ACTIONS_TO_NODE24|node-version.*24' .github/workflows/release.yml .github/workflows/prcheck.ymlRepository: ThinkInAIXYZ/deepchat
Length of output: 491
Upgrade pnpm/action-setup to v4 or later before forcing Node 24 actions.
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24 is enabled, but these jobs still use pnpm/action-setup@v2. The upstream action repository explicitly warns that v2 has stopped working with newer Node.js versions. v2 uses node16 runtime while Node 24 requires node24, causing the action to fail before pnpm install.
🔧 Proposed workflow update
- - name: Setup pnpm
- uses: pnpm/action-setup@v2
+ - name: Setup pnpm
+ uses: pnpm/action-setup@v5
with:
version: 10.13.1Apply the same change to all three platform setup blocks in build.yml (lines 42, 110, 168). The same upgrade is also needed in release.yml and prcheck.yml.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v2 | |
| with: | |
| version: 10.12.1 | |
| version: 10.13.1 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v5 | |
| with: | |
| version: 10.13.1 |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In @.github/workflows/build.yml around lines 41 - 44, The workflow uses
pnpm/action-setup@v2 in the "Setup pnpm" steps while
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24 is enabled; update those steps to use
pnpm/action-setup@v4 (or later) so the action runs on node24 runtime, and apply
the same change to all "Setup pnpm" blocks in this repo's workflow files
(build.yml, release.yml, prcheck.yml) to avoid the node16 vs node24 mismatch.
Ensure any occurrences of "pnpm/action-setup@v2" are replaced with
"pnpm/action-setup@v4" (or a later pinned version) in each workflow file.
| - name: Setup pnpm | ||
| uses: pnpm/action-setup@v2 | ||
| with: | ||
| version: 10.12.1 | ||
| version: 10.13.1 |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Expect no remaining v2 pnpm setup actions after the fix.
rg -n -C2 'pnpm/action-setup@v2' .github/workflowsRepository: ThinkInAIXYZ/deepchat
Length of output: 1946
🌐 Web query:
pnpm/action-setup v2 Node 24 compatibility
💡 Result:
pnpm/action-setup v2 is not compatible with Node.js 24. The official repository explicitly warns that "The v2 version of this action has stopped working with newer Node.js versions. Please, upgrade to the latest version to fix any issues." (sources 1,13,18). v2's action.yml specifies runs: using: node16 (source 16), meaning it runs on Node.js 16 runtime provided by GitHub Actions. With Node 20 deprecated and Node 24 becoming the default (as GitHub runners now support 'node24' per error messages in sources 2,9), v2 fails because 'node16' is outdated and incompatible with current runner environments. Newer versions (v4+, v5.0.0+) have been updated to use Node.js 24 (runs: using: node24), with explicit release notes: "Updated the action to use Node.js 24" (sources 3,10,11). Projects are actively upgrading from v2/v4 to v5+ for Node 24 compatibility (sources 4,19). Use pnpm/action-setup@v5 or later with actions/setup-node for Node 24: - uses: actions/setup-node@v4 with: node-version: 24 cache: pnpm - uses: pnpm/action-setup@v5 with: version: 10
Citations:
- 1: https://github.com/pnpm/action-setup
- 2: https://github.com/pnpm/action-setup?tab=readme-ov-file
- 3: pnpm/action-setup@v2.2.2...v2.2.4
- 4: https://github.com/pnpm/action-setup/
- 5: Bump pnpm/action-setup from 4 to 6 actions/setup-node#1528
- 6: https://github.com/pnpm/action-setup/releases
- 7: Bump pnpm/action-setup from 4 to 5 actions/setup-node#1513
- 8: Update
pnpm/action-setuptonode24version cypress-io/github-action#1569 - 9: https://github.com/pnpm/action-setup/actions/runs/22098436507
- 10: https://github.com/pnpm/action-setup/actions/runs/22098381348
🏁 Script executed:
#!/bin/bash
# Get details on all pnpm/action-setup versions in use and their Node requirements
cd .github/workflows
echo "=== All pnpm/action-setup versions in workflows ==="
rg 'pnpm/action-setup@' -o
echo ""
echo "=== Node version configuration ==="
rg 'node-version|FORCE_JAVASCRIPT' .Repository: ThinkInAIXYZ/deepchat
Length of output: 868
Upgrade pnpm/action-setup from v2 to v5 across all workflows.
pnpm/action-setup@v2 is incompatible with Node 24. The official repository explicitly warns that v2 has stopped working with newer Node.js versions and must be upgraded. v2 runs on the node16 runtime which is no longer supported; v5+ uses node24 and is compatible with the Node 24.14.1 runners configured in your workflows.
This issue affects all workflows with FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true:
.github/workflows/prcheck.yml(line 58).github/workflows/build.yml(lines 42, 110, 168).github/workflows/release.yml(lines 137, 209, 268)
🔧 Required update for all occurrences
- name: Setup pnpm
- uses: pnpm/action-setup@v2
+ uses: pnpm/action-setup@v5
with:
version: 10.13.1📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v2 | |
| with: | |
| version: 10.12.1 | |
| version: 10.13.1 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v5 | |
| with: | |
| version: 10.13.1 |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In @.github/workflows/prcheck.yml around lines 57 - 60, Replace usages of the
GitHub Action reference "pnpm/action-setup@v2" with "pnpm/action-setup@v5"
everywhere this workflow variable is used (all workflows that set
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true), e.g. the step that currently names
"Setup pnpm" and uses pnpm/action-setup@v2; update those occurrences in the same
steps in the other workflows to ensure the action runs on node24-compatible
runners.
| - name: Setup pnpm | ||
| uses: pnpm/action-setup@v2 | ||
| with: | ||
| version: 10.12.1 | ||
| version: 10.13.1 |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Expect no remaining v2 pnpm setup actions after the fix.
rg -n -C2 'pnpm/action-setup@v2' .github/workflowsRepository: ThinkInAIXYZ/deepchat
Length of output: 1946
🏁 Script executed:
#!/bin/bash
# Check for Node 24 forcing in release.yml around line 18
head -30 .github/workflows/release.yml | cat -nRepository: ThinkInAIXYZ/deepchat
Length of output: 964
🌐 Web query:
pnpm/action-setup v2 Node 24 compatibility issues deprecated
💡 Result:
pnpm/action-setup v2 has compatibility issues with Node.js 24 and is effectively deprecated. The official repository explicitly warns: "The v2 version of this action has stopped working with newer Node.js versions. Please, upgrade to the latest version to fix any issues." This stems from v2 using an outdated Node.js runtime (originally node12/node16), which GitHub Actions no longer supports fully after deprecating older Node versions like node16 (EOL) and node20. With Node 24 now the default runner runtime as of 2026, v2 fails due to runtime mismatches, fetch API issues, and invalid 'using' directives in action.yml. Specific issues include: - ERR_PNPM_META_FETCH_FAIL and ERR_INVALID_THIS errors from outdated dependencies like node-fetch on EOL Node versions. - GitHub warnings: "Node.js 20/16 actions are deprecated... pnpm/action-setup@v2". - Failures when GitHub forces node24, as v2's action.yml specifies unsupported runtimes. Upgrade to the latest version (v6+ as of April 2026), which uses 'using: node24', supports pnpm 11, and resolves these. Example workflow: - uses: pnpm/action-setup@v6 with: version: 10 # or omit to use package.json packageManager Note: This action installs pnpm but does not set up Node.js—use actions/setup-node@v4 separately with node-version: 24.
Citations:
- 1: https://github.com/pnpm/action-setup
- 2: https://github.com/pnpm/action-setup?tab=readme-ov-file
- 3: https://github.com/pnpm/action-setup/
- 4: Action failing with setup that has previously been working pnpm/action-setup#135
- 5: pnpm/action-setup@fe02b34...41ff726
- 6: https://github.com/pnpm/action-setup/releases/tag/v6.0.3
- 7: Handle Node.js 20 actions deprecation on github pnpm/action-setup#209
- 8: Update to node 24 - breaking pipelines with old GitHub runners pnpm/action-setup#210
- 9: Should upgrade node20 to node24 pnpm/action-setup#182
🏁 Script executed:
#!/bin/bash
# Check the current setup-node action version used in release.yml
rg -n 'setup-node' .github/workflows/release.yml -A2 -B1Repository: ThinkInAIXYZ/deepchat
Length of output: 454
Upgrade pnpm/action-setup to v6 for Node 24 compatibility.
The release jobs force JavaScript actions to Node 24 but still run pnpm/action-setup@v2, which has stopped working with newer Node.js versions. A release tag could fail at pnpm setup before dependencies are installed.
🔧 Proposed workflow update
- - name: Setup pnpm
- uses: pnpm/action-setup@v2
+ - name: Setup pnpm
+ uses: pnpm/action-setup@v6
with:
version: 10.13.1Apply the same change to all release build jobs.
Also applies to: 208-211, 267-270
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In @.github/workflows/release.yml around lines 136 - 139, Update all occurrences
of the pnpm action in the release workflow to use pnpm/action-setup@v6 (replace
pnpm/action-setup@v2) so the release jobs that force Node 24 can successfully
set up pnpm; locate the action usage lines like "uses: pnpm/action-setup@v2" in
the release.yml (including the instances around the shown diff and the other
occurrences you noted) and change them to "uses: pnpm/action-setup@v6" for each
release build job.
| ## 前置要求 | ||
|
|
||
| - Node.js `>= 20.19` | ||
| - Node.js `24.14.1` recommended | ||
| - pnpm `>= 10.11` | ||
| - Git |
There was a problem hiding this comment.
Mark Node 24.14.1 as required, not just recommended.
package.json now requires >=24.14.1 <25, so this prerequisite should not read as optional guidance.
📝 Proposed doc wording
-- Node.js `24.14.1` recommended
+- Node.js `>= 24.14.1 < 25` required (`24.14.1` recommended)🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@docs/guides/getting-started.md` around lines 5 - 9, Update the prerequisite
under the "## 前置要求" section to mark Node.js 24.14.1 as required (not
recommended) to match package.json's engine range (>=24.14.1 <25); change the
bullet "- Node.js `24.14.1` recommended" to a required statement that explicitly
notes the supported range (e.g., "Node.js >=24.14.1 <25 (required)") so the docs
and package.json remain consistent.
| "type": "module", | ||
| "engines": { | ||
| "node": ">=20.19.0", | ||
| "node": ">=24.14.1 <25", |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Expect every --type node runtime injection to include the Node 24.14.1 runtime pin.
rg -n -C1 'tiny-runtime-injector --type node' package.jsonRepository: ThinkInAIXYZ/deepchat
Length of output: 2817
🌐 Web query:
tiny-runtime-injector npm --type node default version documentation
💡 Result:
tiny-runtime-injector is a CLI/library for downloading lightweight runtimes like Node.js, Bun, Python for projects such as Electron apps. Install via npm install tiny-runtime-injector. Usage for Node: npx tiny-runtime-injector --type node --runtime-version v24.12.0 --dir ./runtime/node (example version shown; no explicit default version found in available sources). Official documentation is in the GitHub repository at https://github.com/zerob13/tiny-runtime-injector, which includes examples for different runtimes. It is a Node.js CLI tool (--type node specifies Node runtime). No npm registry page found in searches, suggesting it may not be published to npm or is very new/low-profile (repo from 2025).
Citations:
- 1: https://github.com/zerob13/tiny-runtime-injector
- 2: https://www.npmjs.com/package/tiny-injector
- 3: https://registry.npmjs.org/tiny-injector
🏁 Script executed:
# Check if there's any configuration or other context about runtime versions
git ls-files | grep -E '(\.npmrc|\.npm|runtime|config)' | head -20Repository: ThinkInAIXYZ/deepchat
Length of output: 896
🏁 Script executed:
# Check if there are any other references to tiny-runtime-injector in the codebase
rg -i 'tiny-runtime-injector' --type-list | head -5
rg -i 'tiny-runtime-injector' -g '*.md' -g '*.json' -g '*.js'Repository: ThinkInAIXYZ/deepchat
Length of output: 3185
🏁 Script executed:
# Check if there's any reference to v22.9.0 in the codebase related to runtime
rg 'v22\.9\.0|22\.9\.0' -g '*.md' -g '*.json' -g '*.js'Repository: ThinkInAIXYZ/deepchat
Length of output: 47
🏁 Script executed:
# Check for any documentation or comments about tiny-runtime-injector defaults
rg -i 'tiny-runtime|default.*node|22\.9|24\.14' docs/ -g '*.md' | head -20Repository: ThinkInAIXYZ/deepchat
Length of output: 127
🌐 Web query:
site:github.com/zerob13/tiny-runtime-injector default Node version
💡 Result:
There is no universal "default" Node.js version, as it depends on the installation method, operating system, and package manager. A recent GitHub project from March 2025 lists Node.js v24.12.0 as its default runtime version.
Citations:
Pin the Node runtime version to 24.14.1 in all installRuntime commands.
The build/release workflows call installRuntime:*, but every tiny-runtime-injector --type node invocation omits a runtime version. Without explicit pinning, the tool may download a mismatched Node runtime instead of the 24.14.1 specified in engines.node and recommended in documentation.
🔧 Proposed runtime alignment
- "installRuntime": "npx -y tiny-runtime-injector --type uv --dir ./runtime/uv --runtime-version 0.9.18 && npx -y tiny-runtime-injector --type node --dir ./runtime/node && npx -y tiny-runtime-injector --type ripgrep --dir ./runtime/ripgrep && npx -y tiny-runtime-injector --type rtk --dir ./runtime/rtk",
+ "installRuntime": "npx -y tiny-runtime-injector --type uv --dir ./runtime/uv --runtime-version 0.9.18 && npx -y tiny-runtime-injector --type node --dir ./runtime/node --runtime-version 24.14.1 && npx -y tiny-runtime-injector --type ripgrep --dir ./runtime/ripgrep && npx -y tiny-runtime-injector --type rtk --dir ./runtime/rtk",Apply the same --runtime-version 24.14.1 addition to each platform-specific --type node command on Lines 53–58.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@package.json` at line 9, The installRuntime commands calling
tiny-runtime-injector with --type node are missing an explicit runtime version;
update each invocation of tiny-runtime-injector --type node in the
installRuntime:* scripts to include --runtime-version 24.14.1 so the runtime
matches the engines.node value (24.14.1) in package.json; look for the
installRuntime:* script entries that call tiny-runtime-injector and append
--runtime-version 24.14.1 to each platform-specific --type node invocation.
Align Electron, Node, and CI toolchain versions for the Node 24 / Electron 40 upgrade.
Summary by CodeRabbit
Chores
Dependencies
Updates
Documentation