chore: update to node 20.19.4 (#19188)

This commit is contained in:
ケイラ
2025-08-06 08:19:02 +02:00
committed by GitHub
parent a2fc26114c
commit 5c88d93207
7 changed files with 42 additions and 26 deletions
+1 -1
View File
@@ -16,7 +16,7 @@ runs:
- name: Setup Node
uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # v4.0.4
with:
node-version: 20.16.0
node-version: 20.19.4
# See https://github.com/actions/setup-node#caching-global-packages-data
cache: "pnpm"
cache-dependency-path: ${{ inputs.directory }}/pnpm-lock.yaml
+6 -6
View File
@@ -4,7 +4,7 @@ FROM rust:slim@sha256:3f391b0678a6e0c88fd26f13e399c9c515ac47354e3cadfee7daee3b21
ENV CARGO_INSTALL_ROOT=/tmp/
# Use more reliable mirrors for Debian packages
RUN sed -i 's|http://deb.debian.org/debian|http://mirrors.edge.kernel.org/debian|g' /etc/apt/sources.list && \
apt-get update || true
apt-get update || true
RUN apt-get update && apt-get install -y libssl-dev openssl pkg-config build-essential
RUN cargo install jj-cli typos-cli watchexec-cli
@@ -126,8 +126,8 @@ RUN mkdir -p /etc/sudoers.d && \
# Use more reliable mirrors for Ubuntu packages
RUN sed -i 's|http://archive.ubuntu.com/ubuntu/|http://mirrors.edge.kernel.org/ubuntu/|g' /etc/apt/sources.list && \
sed -i 's|http://security.ubuntu.com/ubuntu/|http://mirrors.edge.kernel.org/ubuntu/|g' /etc/apt/sources.list && \
apt-get update --quiet && apt-get install --yes \
sed -i 's|http://security.ubuntu.com/ubuntu/|http://mirrors.edge.kernel.org/ubuntu/|g' /etc/apt/sources.list && \
apt-get update --quiet && apt-get install --yes \
ansible \
apt-transport-https \
apt-utils \
@@ -245,7 +245,7 @@ RUN DOCTL_VERSION=$(curl -s "https://api.github.com/repos/digitalocean/doctl/rel
ARG NVM_INSTALL_SHA=bdea8c52186c4dd12657e77e7515509cda5bf9fa5a2f0046bce749e62645076d
# Install frontend utilities
ENV NVM_DIR=/usr/local/nvm
ENV NODE_VERSION=20.16.0
ENV NODE_VERSION=20.19.4
RUN mkdir -p $NVM_DIR
RUN curl -o nvm_install.sh https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.0/install.sh && \
echo "${NVM_INSTALL_SHA} nvm_install.sh" | sha256sum -c && \
@@ -256,8 +256,8 @@ RUN source $NVM_DIR/nvm.sh && \
nvm use $NODE_VERSION
ENV PATH=$NVM_DIR/versions/node/v$NODE_VERSION/bin:$PATH
RUN corepack enable && \
corepack prepare npm@10.8.1 --activate && \
corepack prepare pnpm@9.15.1 --activate
corepack prepare npm@10.8.1 --activate && \
corepack prepare pnpm@9.15.1 --activate
RUN pnpx playwright@1.47.0 install --with-deps chromium
+1 -1
View File
@@ -114,7 +114,7 @@
"semver": "7.6.2",
"tailwind-merge": "2.6.0",
"tailwindcss-animate": "1.0.7",
"tzdata": "1.0.40",
"tzdata": "1.0.44",
"ua-parser-js": "1.0.40",
"ufuzzy": "npm:@leeoniya/ufuzzy@1.0.10",
"undici": "6.21.2",
+5 -5
View File
@@ -258,8 +258,8 @@ importers:
specifier: 1.0.7
version: 1.0.7(tailwindcss@3.4.17(ts-node@10.9.2(@swc/core@1.3.38)(@types/node@20.17.16)(typescript@5.6.3)))
tzdata:
specifier: 1.0.40
version: 1.0.40
specifier: 1.0.44
version: 1.0.44
ua-parser-js:
specifier: 1.0.40
version: 1.0.40
@@ -6071,8 +6071,8 @@ packages:
engines: {node: '>=14.17'}
hasBin: true
tzdata@1.0.40:
resolution: {integrity: sha512-IsWNGfC5GrVPG4ejYJtf3tOlBdJYs0uNzv1a+vkdANHDq2kPg4oAN2UlCfpqrCwErPZVhI6MLA2gkeuXAVnpLg==, tarball: https://registry.npmjs.org/tzdata/-/tzdata-1.0.40.tgz}
tzdata@1.0.44:
resolution: {integrity: sha512-xJ8xcdoFRwFpIQ90QV3WFXJNCO/feNn9vHVsZMJiKmtMYuo7nvF6CTpBc+SgegC1fb/3L+m32ytXT9XrBjrINg==, tarball: https://registry.npmjs.org/tzdata/-/tzdata-1.0.44.tgz}
ua-parser-js@1.0.40:
resolution: {integrity: sha512-z6PJ8Lml+v3ichVojCiB8toQJBuwR42ySM4ezjXIqXK3M0HczmKQ3LF4rhU55PfD99KEEXQG6yb7iOMyvYuHew==, tarball: https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-1.0.40.tgz}
@@ -13020,7 +13020,7 @@ snapshots:
typescript@5.6.3: {}
tzdata@1.0.40: {}
tzdata@1.0.44: {}
ua-parser-js@1.0.40: {}
@@ -71,7 +71,7 @@ describe("validationSchema", () => {
saturday: false,
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorNoDayOfWeek);
expect(validate).toThrow(Language.errorNoDayOfWeek);
});
it("disallows empty startTime when autostart is enabled", () => {
@@ -87,7 +87,7 @@ describe("validationSchema", () => {
startTime: "",
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorNoTime);
expect(validate).toThrow(Language.errorNoTime);
});
it("allows startTime 16:20", () => {
@@ -105,7 +105,7 @@ describe("validationSchema", () => {
startTime: "9:30",
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorTime);
expect(validate).toThrow(Language.errorTime);
});
it("disallows startTime to be HH:m", () => {
@@ -114,7 +114,7 @@ describe("validationSchema", () => {
startTime: "09:5",
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorTime);
expect(validate).toThrow(Language.errorTime);
});
it("disallows an invalid startTime 24:01", () => {
@@ -123,7 +123,7 @@ describe("validationSchema", () => {
startTime: "24:01",
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorTime);
expect(validate).toThrow(Language.errorTime);
});
it("disallows an invalid startTime 09:60", () => {
@@ -132,7 +132,7 @@ describe("validationSchema", () => {
startTime: "09:60",
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorTime);
expect(validate).toThrow(Language.errorTime);
});
it("disallows an invalid timezone Canada/North", () => {
@@ -141,7 +141,7 @@ describe("validationSchema", () => {
timezone: "Canada/North",
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorTimezone);
expect(validate).toThrow(Language.errorTimezone);
});
it.each<[string]>(timeZones.map((zone) => [zone]))(
@@ -162,7 +162,7 @@ describe("validationSchema", () => {
ttl: 24 * 7,
};
const validate = () => validationSchema.validateSync(values);
expect(validate).not.toThrowError();
expect(validate).not.toThrow();
});
it("allows a ttl of 30 days", () => {
@@ -171,7 +171,7 @@ describe("validationSchema", () => {
ttl: 24 * 30,
};
const validate = () => validationSchema.validateSync(values);
expect(validate).not.toThrowError();
expect(validate).not.toThrow();
});
it("disallows a ttl of 30 days + 1 hour", () => {
@@ -180,7 +180,7 @@ describe("validationSchema", () => {
ttl: 24 * 30 + 1,
};
const validate = () => validationSchema.validateSync(values);
expect(validate).toThrowError(Language.errorTtlMax);
expect(validate).toThrow(Language.errorTtlMax);
});
it("allows a ttl of 1.2 hours", () => {
@@ -189,7 +189,7 @@ describe("validationSchema", () => {
ttl: 1.2,
};
const validate = () => validationSchema.validateSync(values);
expect(validate).not.toThrowError();
expect(validate).not.toThrow();
});
});
@@ -158,7 +158,7 @@ export const validationSchema = Yup.object({
try {
dayjs.tz(dayjs(), value);
return true;
} catch (e) {
} catch {
return false;
}
}),
+17 -1
View File
@@ -1,6 +1,22 @@
/**
* Ideally the version of tzdata should correspond to the version of the
* timezone database used by the version of Node we're running our tests
* against. For example, Node v20.19.4 and tzdata@1.0.44 both correspond to
* version 2025b of the ICU timezone:
* https://github.com/nodejs/node/blob/v20.19.4/test/fixtures/tz-version.txt
* https://github.com/rogierschouten/tzdata-generate/releases/tag/v1.0.44
*
* For some reason though, the timezones allowed by `Intl.DateTimeFormat` in
* Node diverged slightly from the timezones present in the tzdata package,
* despite being derived from the same data. Notably, the timezones that we
* filter out below are not allowed by Node as of v20.18.1 and onward–which is
* the version that updated the 20 release line from 2024a to 2024b.
*/
import tzData from "tzdata";
export const timeZones = Object.keys(tzData.zones).sort();
export const timeZones = Object.keys(tzData.zones)
.filter((it) => it !== "Factory" && it !== "null")
.sort();
export const getPreferredTimezone = () =>
Intl.DateTimeFormat().resolvedOptions().timeZone;