Skip to content

Commit 07d5143

Browse files
authored
ci: update runners to test with node 22 instead of 20 (#1831)
This PR will update the node version matrix to a supported version. <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Low Risk** > Documentation and CI matrix changes only; no SDK runtime or application logic is modified. > > **Overview** > Raises the repo’s **minimum Node version from 20 to 22** in contributor docs (`.cursor/rules/development.mdc`, `CLAUDE.md`, `CONTRIBUTING.md`) and aligns several example READMEs (Cloudflare, Electron, Fastly, Vercel) with that requirement. > > **CI** now runs the browser, combined-browser, React, and server-node workflows on **Node 22 and 24** instead of 20 and 22. PR package-size checks for browser and combined-browser run on **Node 24** (previously 22). The server-node custom SOCKS proxy example job uses **Node 22** instead of 20. > > The Fastly example’s `package.json` **`engines.node`** is tightened from `^16 || >=18` to **`>=22`**. > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit b4b04a1. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY -->
1 parent 3ea0f33 commit 07d5143

12 files changed

Lines changed: 15 additions & 15 deletions

File tree

.cursor/rules/development.mdc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ alwaysApply: true
1515
- Tooling packages (development tools)
1616

1717
## Build Requirements
18-
- Node environment version 20 required, this is a minimum.
18+
- Node environment version 22 required, this is a minimum.
1919
- yarn required
2020
- Some projects may have specific environment prerequisites
2121

.github/workflows/browser.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
strategy:
2020
matrix:
2121
# Node versions to run on.
22-
version: [20, 22]
22+
version: [22, 24]
2323

2424
steps:
2525
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
@@ -34,7 +34,7 @@ jobs:
3434
workspace_name: '@launchdarkly/js-client-sdk'
3535
workspace_path: packages/sdk/browser
3636
- name: Check package size
37-
if: github.event_name == 'pull_request' && matrix.version == '22'
37+
if: github.event_name == 'pull_request' && matrix.version == '24'
3838
uses: ./actions/package-size
3939
with:
4040
github_token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/combined-browser.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
strategy:
2020
matrix:
2121
# Node versions to run on.
22-
version: [20, 22]
22+
version: [22, 24]
2323

2424
steps:
2525
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
@@ -34,7 +34,7 @@ jobs:
3434
workspace_name: '@launchdarkly/browser'
3535
workspace_path: packages/sdk/combined-browser
3636
- name: Check package size
37-
if: github.event_name == 'pull_request' && matrix.version == '22'
37+
if: github.event_name == 'pull_request' && matrix.version == '24'
3838
uses: ./actions/package-size
3939
with:
4040
github_token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/react.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
matrix:
1818
# Node versions to run on.
19-
version: [20, 22]
19+
version: [22, 24]
2020
steps:
2121
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2222
- uses: ./actions/setup-yarn

.github/workflows/server-node.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
strategy:
1818
matrix:
1919
# Node versions to run on.
20-
version: [20, 22]
20+
version: [22, 24]
2121

2222
steps:
2323
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
@@ -64,7 +64,7 @@ jobs:
6464
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
6565
- uses: ./actions/setup-yarn
6666
with:
67-
node-version: 20
67+
node-version: 22
6868
# Installs and starts Dante directly on the runner rather than in a container - see
6969
# proxy/setup.sh.
7070
- name: Install and start Dante (SOCKS proxy)

CLAUDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
- Tooling packages (development tools)
1111

1212
## Build Requirements
13-
- Node environment version 20 required (minimum)
13+
- Node environment version 22 required (minimum)
1414
- yarn required
1515
- Some projects may have specific environment prerequisites
1616

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ We encourage pull requests and other contributions from the community. Before su
1414

1515
### Prerequisites
1616

17-
A node environment of version 20 and npm or yarn are required to develop in this repository.
17+
A node environment of version 22 and npm or yarn are required to develop in this repository.
1818

1919
This monorepo may contain projects that are not suitable for execution using node, and those
2020
projects will have specific environment prerequisites.

packages/sdk/cloudflare/example/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ SDK. This app was created with wrangler v2.
55

66
## Prerequisites
77

8-
A node environment of version 16 and yarn are required to develop in this repository.
8+
A node environment of version 22 and yarn are required to develop in this repository.
99
You will also need the wrangler cli installed and a Cloudflare account to setup
1010
the test data required by this example. See the [wrangler docs](https://developers.cloudflare.com/workers/wrangler/commands/#login)
1111
on how to login to your Cloudflare account. Make sure you are logged in before

packages/sdk/electron/example/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ This example was scaffolded with [Electron Forge](https://www.electronforge.io/)
88

99
## Prerequisites
1010

11-
- Node.js 16 or later
11+
- Node.js 22 or later
1212
- Yarn
1313

1414
## Build instructions

packages/sdk/fastly/example/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Cat photo by [Sergey Semin](https://unsplash.com/@feneek?utm_content=creditCopyT
1515

1616
## Prerequisites
1717

18-
A node environment of version 16 and yarn are required to develop in this repository.
18+
A node environment of version 22 and yarn are required to develop in this repository.
1919
You will also need the [Fastly CLI](https://developer.fastly.com/learning/tools/cli) installed and a Fastly account to setup
2020
the test data required by this example. If you don't have a Fastly account, you can sign up for a free developer account [here](https://www.fastly.com/signup?tier=free).
2121

0 commit comments

Comments
 (0)