Skip to content

Commit 0aeb212

Browse files
Revert "deps: bump node to v22.16.0 (#93080)"
This reverts commit 4df68a9. Co-authored-by: asottile-sentry <[email protected]>
1 parent 5101bcd commit 0aeb212

21 files changed

+76
-75
lines changed

.envrc

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,8 +189,7 @@ if [ "${SENTRY_DEVENV_SKIP_FRONTEND}" != "1" ]; then
189189
die "You don't seem to have node installed. Please run devenv sync."
190190
fi
191191

192-
read -r node_version < .node-version
193-
if [ "v${node_version}" != "$(node --version)" ]; then
192+
if ! node -pe "process.exit(Number(!(process.version == 'v' + require('./.volta.json').volta.node )))"; then
194193
die "Unexpected $(command -v node) version. Please run devenv sync."
195194
fi
196195

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ eslint.config.mjs @getsentry/owners-js-bu
132132
jest.config.ts @getsentry/owners-js-build
133133
tsconfig.* @getsentry/owners-js-build
134134
webpack.config.* @getsentry/owners-js-build
135-
.node-version @getsentry/owners-js-deps
135+
.volta.json @getsentry/owners-js-deps
136136
package.json @getsentry/owners-js-deps
137137
pnpm-lock.yaml @getsentry/owners-js-deps
138138

.github/workflows/acceptance.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ jobs:
7272
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
7373
id: setup-node
7474
with:
75-
node-version-file: '.node-version'
75+
node-version-file: '.volta.json'
7676

7777
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
7878

@@ -93,7 +93,7 @@ jobs:
9393
id: nodemodulescache
9494
with:
9595
path: node_modules
96-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
96+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
9797

9898
- name: Install Javascript Dependencies
9999
if: steps.nodemodulescache.outputs.cache-hit != 'true'

.github/workflows/backend.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
5151
id: setup-node
5252
with:
53-
node-version-file: '.node-version'
53+
node-version-file: '.volta.json'
5454

5555
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
5656

.github/workflows/frontend.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
5151
id: setup-node
5252
with:
53-
node-version-file: '.node-version'
53+
node-version-file: '.volta.json'
5454

5555
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
5656

@@ -59,7 +59,7 @@ jobs:
5959
id: nodemodulescache
6060
with:
6161
path: node_modules
62-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
62+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
6363

6464
- name: Install Javascript Dependencies
6565
if: steps.nodemodulescache.outputs.cache-hit != 'true'
@@ -86,7 +86,7 @@ jobs:
8686
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
8787
id: setup-node
8888
with:
89-
node-version-file: '.node-version'
89+
node-version-file: '.volta.json'
9090

9191
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
9292

@@ -95,7 +95,7 @@ jobs:
9595
id: nodemodulescache
9696
with:
9797
path: node_modules
98-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
98+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
9999

100100
- name: Install Javascript Dependencies
101101
if: steps.nodemodulescache.outputs.cache-hit != 'true'
@@ -122,7 +122,7 @@ jobs:
122122
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
123123
id: setup-node
124124
with:
125-
node-version-file: '.node-version'
125+
node-version-file: '.volta.json'
126126

127127
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
128128

@@ -131,7 +131,7 @@ jobs:
131131
id: nodemodulescache
132132
with:
133133
path: node_modules
134-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
134+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
135135

136136
- name: Install Javascript Dependencies
137137
if: steps.nodemodulescache.outputs.cache-hit != 'true'
@@ -175,7 +175,7 @@ jobs:
175175
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
176176
id: setup-node
177177
with:
178-
node-version-file: '.node-version'
178+
node-version-file: '.volta.json'
179179

180180
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
181181

@@ -184,7 +184,7 @@ jobs:
184184
id: nodemodulescache
185185
with:
186186
path: node_modules
187-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
187+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
188188

189189
- name: Install Javascript Dependencies
190190
if: steps.nodemodulescache.outputs.cache-hit != 'true'

.github/workflows/jest-balance.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
1717
id: setup-node
1818
with:
19-
node-version-file: '.node-version'
19+
node-version-file: '.volta.json'
2020

2121
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
2222

@@ -25,7 +25,7 @@ jobs:
2525
id: nodemodulescache
2626
with:
2727
path: node_modules
28-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
28+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
2929

3030
- name: Install Javascript Dependencies
3131
if: steps.nodemodulescache.outputs.cache-hit != 'true'

.github/workflows/openapi-diff.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
4545
id: setup-node
4646
with:
47-
node-version-file: '.node-version'
47+
node-version-file: '.volta.json'
4848

4949
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
5050

.github/workflows/openapi.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
if: steps.changes.outputs.api_docs == 'true'
4949
id: setup-node
5050
with:
51-
node-version-file: '.node-version'
51+
node-version-file: '.volta.json'
5252

5353
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
5454

.github/workflows/pre-commit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ jobs:
5656
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
5757
id: setup-node
5858
with:
59-
node-version-file: '.node-version'
59+
node-version-file: '.volta.json'
6060

6161
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
6262

@@ -65,7 +65,7 @@ jobs:
6565
id: nodemodulescache
6666
with:
6767
path: node_modules
68-
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.node-version') }}
68+
key: ${{ runner.os }}-node-modules-${{ hashFiles('pnpm-lock.yaml', 'api-docs/pnpm-lock.yaml', '.volta.json') }}
6969

7070
- name: Install Javascript Dependencies
7171
if: steps.nodemodulescache.outputs.cache-hit != 'true'

.github/workflows/self-hosted.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
3737
id: setup-node
3838
with:
39-
node-version-file: '.node-version'
39+
node-version-file: '.volta.json'
4040

4141
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
4242

@@ -63,7 +63,7 @@ jobs:
6363
id: nodemodulescache
6464
with:
6565
path: node_modules
66-
key: ${{ runner.os }}-self-hosted-node-modules-${{ hashFiles('pnpm-lock.yaml', '.node-version') }}
66+
key: ${{ runner.os }}-self-hosted-node-modules-${{ hashFiles('pnpm-lock.yaml', '.volta.json') }}
6767

6868
- name: Install Javascript Dependencies
6969
if: steps.nodemodulescache.outputs.cache-hit != 'true'

.github/workflows/sync-labels.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
2727
id: setup-node
2828
with:
29-
node-version-file: '.node-version'
29+
node-version-file: '.volta.json'
3030

3131
- uses: pnpm/action-setup@36de12bed180fa130ed56a35e7344f2fa7a820ab # v4
3232

.node-version

Lines changed: 0 additions & 1 deletion
This file was deleted.

.volta.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"volta": {
3+
"node": "22.11.0"
4+
}
5+
}

api-docs/.node-version

Lines changed: 0 additions & 1 deletion
This file was deleted.

api-docs/.volta.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"volta": {
3+
"node": "22.11.0"
4+
}
5+
}

config/tsconfig.base.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,5 +122,15 @@
122122
]
123123
},
124124
"include": ["../static/app", "../static/gsApp", "../tests/js"],
125-
"exclude": ["../node_modules", "../**/*.benchmark.ts"]
125+
"exclude": ["../node_modules", "../**/*.benchmark.ts"],
126+
"ts-node": {
127+
"transpileOnly": true,
128+
"compilerOptions": {
129+
// TODO: We should be able to use "node16" on next major version of jest
130+
// https://github.com/jestjs/jest/pull/14739
131+
"module": "commonjs",
132+
// TODO: node10 will be deprecated in typescript 6.0
133+
"moduleResolution": "node10"
134+
}
135+
}
126136
}

devenv/config.ini

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,15 @@ linux_arm64 = https://github.com/indygreg/python-build-standalone/releases/downl
3131
linux_arm64_sha256 = d37aef7bdf5c27f7d006918f7cedb31f4ba07c88f61baac4ffbe0bee6d4b5248
3232

3333
[node]
34-
# upstream (https://nodejs.org/dist/) is not reliable enough
35-
# ask someone in team-devinfra to upload for you
36-
darwin_x86_64 = https://storage.googleapis.com/sentry-dev-infra-assets/node/node-v22.16.0-darwin-x64.tar.xz
37-
darwin_x86_64_sha256 = 5c34638f2c0e3f3aaa7b3a94b58304765a169730da1896ebba8515ea4d987a9c
38-
darwin_arm64 = https://storage.googleapis.com/sentry-dev-infra-assets/node/node-v22.16.0-darwin-arm64.tar.xz
39-
darwin_arm64_sha256 = aaf7fc3c936f1b359bc312b63638e41f258689ac2303966ad932cda18c54ea00
40-
linux_x86_64 = https://storage.googleapis.com/sentry-dev-infra-assets/node/node-v22.16.0-linux-x64.tar.xz
41-
linux_x86_64_sha256 = f4cb75bb036f0d0eddf6b79d9596df1aaab9ddccd6a20bf489be5abe9467e84e
34+
# upstream (https://nodejs.org/dist/) is not reliable enough so we've mirrored it to GCS
35+
darwin_x86_64 = https://storage.googleapis.com/sentry-dev-infra-assets/node/node-v22.11.0-darwin-x64.tar.xz
36+
darwin_x86_64_sha256 = ab28d1784625d151e3f608a9412a009118f376118ed842ae643f8c2efdfb0af6
37+
darwin_arm64 = https://storage.googleapis.com/sentry-dev-infra-assets/node/node-v22.11.0-darwin-arm64.tar.xz
38+
darwin_arm64_sha256 = c379a90c6aa605b74042a233ddcda4247b347ba5732007d280e44422cc8f9ecb
39+
linux_x86_64 = https://storage.googleapis.com/sentry-dev-infra-assets/node/node-v22.11.0-linux-x64.tar.xz
40+
linux_x86_64_sha256 = 83bf07dd343002a26211cf1fcd46a9d9534219aad42ee02847816940bf610a72
4241
# used for autoupdate
43-
version = v22.16.0
42+
version = v22.11.0
4443

4544
# kept here only for compatibility with older `devenv`
4645
[python]

devenv/sync.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -220,10 +220,6 @@ def main(context: dict[str, str]) -> int:
220220
),
221221
{
222222
"NODE_ENV": "development",
223-
# this ensures interactive prompts are answered by
224-
# the defaults (usually yes), useful for recreating
225-
# node_modules if configuration or node version changes
226-
"CI": "true",
227223
},
228224
),
229225
),

knip.config.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@ import type {KnipConfig} from 'knip';
44
const productionEntryPoints = [
55
// the main entry points - app, gsAdmin & gsApp
66
'static/app/index.tsx',
7-
// chartcuterie build script
8-
'config/build-chartcuterie.ts',
97
// dynamic imports _not_ recognized by knip
108
'static/app/bootstrap/{index,initializeMain}.tsx',
119
'static/gsApp/initializeBundleMetrics.tsx',

package.json

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -264,12 +264,12 @@
264264
"build-deprecated-docs": "pnpm run install-api-docs && node --experimental-transform-types api-docs/index.ts api-docs/openapi.json tests/apidocs/openapi-deprecated.json",
265265
"diff-docs": "pnpm run install-api-docs && node --experimental-transform-types api-docs/openapi-diff.ts",
266266
"deref-api-docs": "node --experimental-transform-types api-docs/index.ts tests/apidocs/openapi-spectacular.json tests/apidocs/openapi-derefed.json",
267-
"build-chartcuterie-config": "node --experimental-transform-types config/build-chartcuterie.ts",
268-
"build-acceptance": "CODECOV_ENABLE_BA=false IS_ACCEPTANCE_TEST=1 NODE_ENV=production pnpm run build",
269-
"build-production": "NODE_OPTIONS='--experimental-transform-types' NODE_ENV=production rspack --mode production --config ./rspack.config.ts",
270-
"build": "NODE_OPTIONS='--max-old-space-size=4096 --experimental-transform-types' rspack --config ./rspack.config.ts",
267+
"build-chartcuterie-config": "node --experimental-strip-types config/build-chartcuterie.ts",
268+
"build-acceptance": "CODECOV_ENABLE_BA=false IS_ACCEPTANCE_TEST=1 NODE_ENV=production rspack",
269+
"build-production": "NODE_ENV=production rspack --mode production",
270+
"build": "NODE_OPTIONS=--max-old-space-size=4096 rspack",
271271
"build-js-loader": "node --experimental-transform-types scripts/build-js-loader.ts",
272-
"build-js-po": "node --experimental-transform-types build-utils/ts-extract-gettext.ts",
272+
"build-js-po": "node --experimental-strip-types build-utils/ts-extract-gettext.ts",
273273
"validate-api-examples": "pnpm run --dir api-docs openapi-examples-validator ../tests/apidocs/openapi-derefed.json --no-additional-properties",
274274
"mkcert-localhost": "mkcert -key-file config/localhost-key.pem -cert-file config/localhost.pem localhost 127.0.0.1 dev.getsentry.net *.dev.getsentry.net && mkcert -install",
275275
"https-proxy": "caddy run --config - <<< '{\"apps\":{\"http\":{\"servers\":{\"srv0\":{\"listen\":[\":8003\"],\"routes\":[{\"handle\":[{\"handler\":\"reverse_proxy\",\"upstreams\":[{\"dial\":\"localhost:8000\"}]}]}],\"tls_connection_policies\":[{\"certificate_selection\":{\"any_tag\":[\"cert0\"]}}]}}},\"tls\":{\"certificates\":{\"load_files\":[{\"certificate\":\"./config/localhost.pem\",\"key\":\"./config/localhost-key.pem\",\"tags\":[\"cert0\"]}]}}}}'",
@@ -296,6 +296,9 @@
296296
]
297297
},
298298
"packageManager": "[email protected]",
299+
"volta": {
300+
"extends": ".volta.json"
301+
},
299302
"prettier": {
300303
"bracketSpacing": false,
301304
"bracketSameLine": false,

0 commit comments

Comments
 (0)