ci: bump node versions to 22-26#1972
Conversation
Signed-off-by: jongleberry <jonathanrichardong@gmail.com>
📝 WalkthroughWalkthroughThe Node.js CI workflow in 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
Reviewer's guide (collapsed on small PRs)Reviewer's GuideUpdates the Node.js versions used in the CI workflow matrix to newer LTS/current releases. Flow diagram for updated CI Node.js version matrixflowchart LR
A[GitHub Actions workflow node.js.yml] --> B[CI job build]
B --> C{matrix.node-version}
C --> D[Node 22.x]
C --> E[Node 24.x]
C --> F[Node 26.x]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- Consider whether dropping Node 18.x and 20.x from the matrix is intentional, as this will stop catching compatibility issues for users still on the current LTS line; if you still support them, keep at least the oldest supported LTS in the CI matrix.
- If the project defines an
enginesfield or other version constraints, make sure they are updated to match the new 22.x–26.x support range so CI and declared support stay aligned.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Consider whether dropping Node 18.x and 20.x from the matrix is intentional, as this will stop catching compatibility issues for users still on the current LTS line; if you still support them, keep at least the oldest supported LTS in the CI matrix.
- If the project defines an `engines` field or other version constraints, make sure they are updated to match the new 22.x–26.x support range so CI and declared support stay aligned.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1972 +/- ##
=======================================
Coverage 99.90% 99.90%
=======================================
Files 9 9
Lines 2106 2106
=======================================
Hits 2104 2104
Misses 2 2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
.github/workflows/node.js.yml (1)
16-16: ⚡ Quick winNode.js 26.x is officially released (Current), but not yet LTS—align with CI stability intent.
Using
node-version: [22.x, 24.x, 26.x]is fine from a release-availability standpoint: Node.js 26 has been released and is actively maintained as the “Current” line in May 2026. However, it’s not LTS yet (LTS starts in October 2026), so if the CI goal is production-grade stability signals, consider testing LTS majors only (or pinning) instead of the non-LTS26.x.🤖 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/node.js.yml at line 16, Update the GitHub Actions matrix under the node-version key to avoid testing the non-LTS Node 26.x by removing 26.x from the array (or alternatively pinning exact LTS patch versions); specifically edit the node-version: [22.x, 24.x, 26.x] entry in the workflow to something like node-version: [22.x, 24.x] (or node-version: [22.20.0, 24.17.0] if you prefer pinned LTS releases) so CI aligns with production-grade LTS stability intent.
🤖 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 @.github/workflows/node.js.yml:
- Line 16: CI matrix is missing the minimum supported Node version: update the
node-version matrix entry (node-version: [22.x, 24.x, 26.x]) to include the
declared minimum (e.g., add 18.x and/or 20.x) so CI validates engines.node, or
alternatively change package.json's engines.node to match the tested minimum
(e.g., ">=22") to keep declarations in sync; modify the node-version array in
the workflow or the engines.node field in package.json accordingly and commit
the matching change.
---
Nitpick comments:
In @.github/workflows/node.js.yml:
- Line 16: Update the GitHub Actions matrix under the node-version key to avoid
testing the non-LTS Node 26.x by removing 26.x from the array (or alternatively
pinning exact LTS patch versions); specifically edit the node-version: [22.x,
24.x, 26.x] entry in the workflow to something like node-version: [22.x, 24.x]
(or node-version: [22.20.0, 24.17.0] if you prefer pinned LTS releases) so CI
aligns with production-grade LTS stability intent.
🪄 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: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: a452be8d-b11c-4c91-8a7e-4985cdb6c849
📒 Files selected for processing (1)
.github/workflows/node.js.yml
| strategy: | ||
| matrix: | ||
| node-version: [18.x, 20.x, 22.x] | ||
| node-version: [22.x, 24.x, 26.x] |
There was a problem hiding this comment.
Testing gap: CI doesn't validate the minimum supported Node version.
The matrix tests Node 22.x, 24.x, and 26.x, but package.json declares support for Node >= 18. This means Node 18.x and 20.x are not being tested in CI, creating a risk that breaking changes for these versions could be merged without detection.
Consider either:
- Adding Node 18.x to the matrix to validate the minimum supported version, or
- Updating
package.jsonengines.nodeto reflect the actual minimum tested version (e.g.,">= 22")
Testing the minimum supported version is a best practice to ensure compatibility promises are reliable.
✅ Option 1: Add minimum version to test matrix
- node-version: [22.x, 24.x, 26.x]
+ node-version: [18.x, 22.x, 24.x, 26.x]📝 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.
| node-version: [22.x, 24.x, 26.x] | |
| node-version: [18.x, 22.x, 24.x, 26.x] |
🤖 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/node.js.yml at line 16, CI matrix is missing the minimum
supported Node version: update the node-version matrix entry (node-version:
[22.x, 24.x, 26.x]) to include the declared minimum (e.g., add 18.x and/or 20.x)
so CI validates engines.node, or alternatively change package.json's
engines.node to match the tested minimum (e.g., ">=22") to keep declarations in
sync; modify the node-version array in the workflow or the engines.node field in
package.json accordingly and commit the matching change.
Summary by Sourcery
CI:
Summary by CodeRabbit