Skip to content

ci: bump node versions to 22-26#1972

Open
jonathanong wants to merge 1 commit into
masterfrom
node-26
Open

ci: bump node versions to 22-26#1972
jonathanong wants to merge 1 commit into
masterfrom
node-26

Conversation

@jonathanong

@jonathanong jonathanong commented May 25, 2026

Copy link
Copy Markdown
Member

Summary by Sourcery

CI:

  • Adjust CI workflow to drop Node 18/20 and add Node 24/26 in the test matrix.

Summary by CodeRabbit

  • Chores
    • Updated testing infrastructure to validate compatibility with Node.js versions 22.x, 24.x, and 26.x.

Review Change Stack

Signed-off-by: jongleberry <jonathanrichardong@gmail.com>
@coderabbitai

coderabbitai Bot commented May 25, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

The Node.js CI workflow in .github/workflows/node.js.yml is updated to test against a newer set of Node versions. The node-version matrix is changed to [22.x, 24.x, 26.x], replacing the previous version set. No workflow triggers, build steps, or actions are modified.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'ci: bump node versions to 22-26' clearly and specifically summarizes the main change: updating the Node.js CI workflow test matrix from previous versions to versions 22, 24, and 26.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

@sourcery-ai

sourcery-ai Bot commented May 25, 2026

Copy link
Copy Markdown
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Updates the Node.js versions used in the CI workflow matrix to newer LTS/current releases.

Flow diagram for updated CI Node.js version matrix

flowchart 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]
Loading

File-Level Changes

Change Details Files
Update CI matrix to test against newer Node.js major versions.
  • Replace Node.js 18.x and 20.x entries in the workflow matrix with 24.x and 26.x
  • Keep 22.x in the matrix to continue testing against that line
  • Leave the rest of the workflow steps and configuration unchanged
.github/workflows/node.js.yml

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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 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.
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.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@codecov

codecov Bot commented May 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.90%. Comparing base (4b12945) to head (c837aeb).

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.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
.github/workflows/node.js.yml (1)

16-16: ⚡ Quick win

Node.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-LTS 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, 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

📥 Commits

Reviewing files that changed from the base of the PR and between 4b12945 and c837aeb.

📒 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]

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 | 🟠 Major | ⚡ Quick win

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:

  1. Adding Node 18.x to the matrix to validate the minimum supported version, or
  2. Updating package.json engines.node to 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.

Suggested change
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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant