Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4e7f6cb

Browse files
committed
chore: bump node engine version
In the nix flake's devshell, we used `nodejs_20` (20.18.3).`vite@7.1.4` requires a newer node version (^20.19.0).This commit bumps the flake's node version to `nodejs_22`, andupdates the allowed engine versions in the sites package.json.```bash❯ make gengenerateok github.com/coder/coder/v2/coderd/database/gentest 0.649sok github.com/coder/coder/v2/cli 3.258sok github.com/coder/coder/v2/coderd 3.655sok github.com/coder/coder/v2/coderd/notifications 3.322sok github.com/coder/coder/v2/enterprise/cli 2.238sok github.com/coder/coder/v2/enterprise/tailnet 0.741sok github.com/coder/coder/v2/helm/coder/tests 2.891sok github.com/coder/coder/v2/helm/provisioner/tests 1.336sok github.com/coder/coder/v2/provisioner/terraform 0.755sok github.com/coder/coder/v2/tailnet 0.697s+ pnpm installLockfile is up to date, resolution step is skipped ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)Your Node version is incompatible with "vite@7.1.4(@types/node@20.17.16)(jiti@2.4.2)(yaml@2.7.0)".Expected version: ^20.19.0 || >=22.12.0Got: v20.18.3This is happening because the package's manifest has an engines.node field specified.To fix this issue, install the required Node version.make: *** [Makefile:416: site/node_modules/.installed] Error 1```
1 parent6238937 commit4e7f6cb

File tree

7 files changed

+25
-12
lines changed

7 files changed

+25
-12
lines changed

‎.github/actions/setup-node/action.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ runs:
1616
-name:Setup Node
1717
uses:actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6# v4.0.4
1818
with:
19-
node-version:20.19.4
19+
node-version:22.14.0
2020
# See https://github.com/actions/setup-node#caching-global-packages-data
2121
cache:"pnpm"
2222
cache-dependency-path:${{ inputs.directory }}/pnpm-lock.yaml

‎dogfood/coder/Dockerfile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ RUN DOCTL_VERSION=$(curl -s "https://api.github.com/repos/digitalocean/doctl/rel
245245
ARG NVM_INSTALL_SHA=bdea8c52186c4dd12657e77e7515509cda5bf9fa5a2f0046bce749e62645076d
246246
# Install frontend utilities
247247
ENV NVM_DIR=/usr/local/nvm
248-
ENV NODE_VERSION=20.19.4
248+
ENV NODE_VERSION=22.14.0
249249
RUN mkdir -p $NVM_DIR
250250
RUN curl -o nvm_install.sh https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.0/install.sh && \
251251
echo"${NVM_INSTALL_SHA} nvm_install.sh" | sha256sum -c && \

‎flake.nix‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
formatter=pkgs.nixfmt-rfc-style;
5858

59-
nodejs=pkgs.nodejs_20;
59+
nodejs=pkgs.nodejs_22;
6060
pnpm=pkgs.pnpm_10.override{
6161
inheritnodejs;# Ensure it points to the above nodejs version
6262
};
@@ -147,7 +147,6 @@
147147
less
148148
mockgen
149149
moreutils
150-
neovim
151150
nfpm
152151
nix-prefetch-git
153152
nodejs

‎offlinedocs/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
},
4343
"engines": {
4444
"npm":">=9.0.0 <10.0.0",
45-
"node":">=18.0.0 <21.0.0"
45+
"node":">=18.0.0 <23.0.0"
4646
},
4747
"pnpm": {
4848
"overrides": {

‎site/package.json‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@
114114
"semver":"7.6.2",
115115
"tailwind-merge":"2.6.0",
116116
"tailwindcss-animate":"1.0.7",
117-
"tzdata":"1.0.44",
117+
"tzdata":"1.0.46",
118118
"ua-parser-js":"1.0.40",
119119
"ufuzzy":"npm:@leeoniya/ufuzzy@1.0.10",
120120
"undici":"6.21.2",
@@ -195,7 +195,7 @@
195195
},
196196
"engines": {
197197
"pnpm":">=10.0.0 <11.0.0",
198-
"node":">=18.0.0 <21.0.0"
198+
"node":">=18.0.0 <23.0.0"
199199
},
200200
"pnpm": {
201201
"overrides": {

‎site/pnpm-lock.yaml‎

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎site/src/utils/timeZones.ts‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,22 @@
1414
*/
1515
importtzDatafrom"tzdata";
1616

17+
// Build a list of timezones from tzdata, then filter out any zones that the
18+
// current runtime (Node/JS engine) does not accept via Intl. This keeps the
19+
// UI options aligned with what dayjs/Intl can actually parse, preventing
20+
// validation errors for zones like "America/Coyhaique" in newer Node releases.
1721
exportconsttimeZones=Object.keys(tzData.zones)
1822
.filter((it)=>it!=="Factory"&&it!=="null")
23+
.filter((zone)=>{
24+
try{
25+
// Accept both canonical and alias names that the runtime recognizes.
26+
// Will throw for unsupported zones.
27+
newIntl.DateTimeFormat("en-US",{timeZone:zone});
28+
returntrue;
29+
}catch{
30+
returnfalse;
31+
}
32+
})
1933
.sort();
2034

2135
exportconstgetPreferredTimezone=()=>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp