From ea6c4b1d19aa037898308233f3b824171754fabd Mon Sep 17 00:00:00 2001 From: McKayla Washburn Date: Tue, 1 Jul 2025 19:01:29 +0000 Subject: [PATCH 1/5] update node --- dogfood/coder/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dogfood/coder/Dockerfile b/dogfood/coder/Dockerfile index dbafcd7add427..0c64ed5f96bd7 100644 --- a/dogfood/coder/Dockerfile +++ b/dogfood/coder/Dockerfile @@ -242,7 +242,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.3 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 && \ From d2f4a582309e5c1614d2874ccbcaedbb37aa0f62 Mon Sep 17 00:00:00 2001 From: McKayla Washburn Date: Tue, 1 Jul 2025 19:02:36 +0000 Subject: [PATCH 2/5] update in ci --- .github/actions/setup-node/action.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/setup-node/action.yaml b/.github/actions/setup-node/action.yaml index 02ffa14312ffe..44b7058f15307 100644 --- a/.github/actions/setup-node/action.yaml +++ b/.github/actions/setup-node/action.yaml @@ -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.3 # See https://github.com/actions/setup-node#caching-global-packages-data cache: "pnpm" cache-dependency-path: ${{ inputs.directory }}/pnpm-lock.yaml From b6273be2f93881ddd8aeb248c401ab094b00ecdd Mon Sep 17 00:00:00 2001 From: McKayla Washburn Date: Tue, 5 Aug 2025 19:52:22 +0000 Subject: [PATCH 3/5] bump --- .github/actions/setup-node/action.yaml | 2 +- dogfood/coder/Dockerfile | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/actions/setup-node/action.yaml b/.github/actions/setup-node/action.yaml index 44b7058f15307..6ed9985185746 100644 --- a/.github/actions/setup-node/action.yaml +++ b/.github/actions/setup-node/action.yaml @@ -16,7 +16,7 @@ runs: - name: Setup Node uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # v4.0.4 with: - node-version: 20.19.3 + 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 diff --git a/dogfood/coder/Dockerfile b/dogfood/coder/Dockerfile index 0c64ed5f96bd7..4b95b17b90281 100644 --- a/dogfood/coder/Dockerfile +++ b/dogfood/coder/Dockerfile @@ -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 @@ -123,8 +123,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 \ @@ -242,7 +242,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.19.3 +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 && \ @@ -253,7 +253,7 @@ RUN source $NVM_DIR/nvm.sh && \ nvm use $NODE_VERSION ENV PATH=$NVM_DIR/versions/node/v$NODE_VERSION/bin:$PATH # Allow patch updates for npm and pnpm -RUN npm install -g npm@10.8.1 --integrity=sha512-Dp1C6SvSMYQI7YHq/y2l94uvI+59Eqbu1EpuKQHQ8p16txXRuRit5gH3Lnaagk2aXDIjg/Iru9pd05bnneKgdw== +RUN npm install -g npm@10.9.3 --integrity=sha512-Dp1C6SvSMYQI7YHq/y2l94uvI+59Eqbu1EpuKQHQ8p16txXRuRit5gH3Lnaagk2aXDIjg/Iru9pd05bnneKgdw== RUN npm install -g pnpm@9.15.1 --integrity=sha512-GstWXmGT7769p3JwKVBGkVDPErzHZCYudYfnHRncmKQj3/lTblfqRMSb33kP9pToPCe+X6oj1n4MAztYO+S/zw== RUN pnpx playwright@1.47.0 install --with-deps chromium From def2ebe6e6f14d655d741401e27532f9fcd6f30b Mon Sep 17 00:00:00 2001 From: McKayla Washburn Date: Tue, 5 Aug 2025 20:02:40 +0000 Subject: [PATCH 4/5] lints --- .../WorkspaceScheduleForm.test.tsx | 22 +++++++++---------- .../WorkspaceScheduleForm.tsx | 2 +- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.test.tsx b/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.test.tsx index 1e9b50292887b..59f2798d76568 100644 --- a/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.test.tsx +++ b/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.test.tsx @@ -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(); }); }); diff --git a/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.tsx b/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.tsx index 813018f35543a..cdf1f5b0d9726 100644 --- a/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.tsx +++ b/site/src/pages/WorkspaceSettingsPage/WorkspaceSchedulePage/WorkspaceScheduleForm.tsx @@ -158,7 +158,7 @@ export const validationSchema = Yup.object({ try { dayjs.tz(dayjs(), value); return true; - } catch (e) { + } catch { return false; } }), From 66bafa3e2e615ced22478681c7c21c29a484b808 Mon Sep 17 00:00:00 2001 From: McKayla Washburn Date: Tue, 5 Aug 2025 21:07:33 +0000 Subject: [PATCH 5/5] timezone weirdness abounds --- site/package.json | 2 +- site/pnpm-lock.yaml | 10 +++++----- site/src/utils/timeZones.ts | 18 +++++++++++++++++- 3 files changed, 23 insertions(+), 7 deletions(-) diff --git a/site/package.json b/site/package.json index 75ff5a33d3a33..b05cd6a890562 100644 --- a/site/package.json +++ b/site/package.json @@ -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", diff --git a/site/pnpm-lock.yaml b/site/pnpm-lock.yaml index b5ce1062e605a..2039cc3e62bae 100644 --- a/site/pnpm-lock.yaml +++ b/site/pnpm-lock.yaml @@ -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: {} diff --git a/site/src/utils/timeZones.ts b/site/src/utils/timeZones.ts index d69574b1ae382..caadd191f0b36 100644 --- a/site/src/utils/timeZones.ts +++ b/site/src/utils/timeZones.ts @@ -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; pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy