From 1ac138d51159bbecc518e6eea2db31d3943f9e0f Mon Sep 17 00:00:00 2001 From: maclane Date: Mon, 27 Jul 2026 12:46:49 -0400 Subject: [PATCH] build(ci)!: move the solidity toolchain to Node 24 The end of the chain, and the reason for it. Five workflows, two Dockerfiles and two `engines` fields go from Node 18.15.0 -- end of life since 2025-04-30 -- straight to 24.11.1, the current LTS, supported until 2028-04-30. This was not reachable before. Node 24 needs hardhat >= 2.26, because below it Hardhat's solc download fails with HH502: npm's undici and Node 24's bundled undici share a global-dispatcher symbol, so the download reaches Node's internal dispatcher, which rejects `maxRedirections`. hardhat >= 2.21 in turn broke @defi-wonderland/smock, and no smock version ever reached 2.26. The dependency was archived, so no version ever would. That is why #4203 removed it and #4204 raised hardhat before this commit could exist. The failure that started it, now passing on the same machine and the same runtime -- cold compiler cache, which is what a CI runner always has: before Error HH502: Couldn't download compiler versions list. after Compiled 75 Solidity files successfully Verified, whole suite, both packages, on Node 24.11.1: ecdsa 673 passing / 44 pending / 0 failing random-beacon 955 passing / 0 pending / 0 failing Docker base images are pinned to `node:24.11.1-alpine` rather than the floating `node:24-alpine`, matching the exact version CI pins, so the two runtimes cannot drift apart. This supersedes #4201, which moved the same nine files from 18 to 22 while 24 was still out of reach. If that lands first this needs a one-token rebase per site; if this chain lands, #4201 can be closed. BREAKING CHANGE: the solidity packages now require Node >= 24.0.0. Contributors on Node 18 or 20 will need to upgrade. Co-Authored-By: Claude Opus 5 (1M context) --- .github/workflows/contracts-ecdsa.yml | 12 ++++++------ .github/workflows/contracts-random-beacon.yml | 12 ++++++------ .github/workflows/npm-ecdsa.yml | 2 +- .github/workflows/npm-random-beacon.yml | 2 +- .github/workflows/reusable-solidity-docs.yml | 2 +- solidity/ecdsa/Dockerfile | 2 +- solidity/ecdsa/package.json | 2 +- solidity/random-beacon/Dockerfile | 2 +- solidity/random-beacon/package.json | 2 +- 9 files changed, 19 insertions(+), 19 deletions(-) diff --git a/.github/workflows/contracts-ecdsa.yml b/.github/workflows/contracts-ecdsa.yml index b3c4ecd237..8f51955187 100644 --- a/.github/workflows/contracts-ecdsa.yml +++ b/.github/workflows/contracts-ecdsa.yml @@ -55,7 +55,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: @@ -81,7 +81,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: actions/setup-python@v4 with: @@ -123,7 +123,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: @@ -150,7 +150,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: @@ -183,7 +183,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" registry-url: "https://registry.npmjs.org" - uses: ./.github/actions/install-yarn-deps @@ -283,7 +283,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" registry-url: "https://registry.npmjs.org" - uses: ./.github/actions/install-yarn-deps diff --git a/.github/workflows/contracts-random-beacon.yml b/.github/workflows/contracts-random-beacon.yml index a7be8c6eab..d26528ae02 100644 --- a/.github/workflows/contracts-random-beacon.yml +++ b/.github/workflows/contracts-random-beacon.yml @@ -55,7 +55,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: @@ -81,7 +81,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: actions/setup-python@v4 with: @@ -121,7 +121,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: @@ -148,7 +148,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: @@ -181,7 +181,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" registry-url: "https://registry.npmjs.org" - uses: ./.github/actions/install-yarn-deps @@ -279,7 +279,7 @@ jobs: # Using fixed version, because 18.16 was sometimes causing issues with # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877 - node-version: "18.15.0" + node-version: "24.11.1" registry-url: "https://registry.npmjs.org" - uses: ./.github/actions/install-yarn-deps diff --git a/.github/workflows/npm-ecdsa.yml b/.github/workflows/npm-ecdsa.yml index f069ce2ba7..c1db4a1a76 100644 --- a/.github/workflows/npm-ecdsa.yml +++ b/.github/workflows/npm-ecdsa.yml @@ -28,7 +28,7 @@ jobs: # Using fixed version, because 18.16 may cause issues with the # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877. - node-version: "18.15.0" + node-version: "24.11.1" registry-url: "https://registry.npmjs.org" - uses: ./.github/actions/install-yarn-deps diff --git a/.github/workflows/npm-random-beacon.yml b/.github/workflows/npm-random-beacon.yml index c7a342f009..15c8b0abe3 100644 --- a/.github/workflows/npm-random-beacon.yml +++ b/.github/workflows/npm-random-beacon.yml @@ -28,7 +28,7 @@ jobs: # Using fixed version, because 18.16 may cause issues with the # artifacts generation during `hardhat compile` - see # https://github.com/NomicFoundation/hardhat/issues/3877. - node-version: "18.15.0" + node-version: "24.11.1" registry-url: "https://registry.npmjs.org" - uses: ./.github/actions/setup-git-for-yarn diff --git a/.github/workflows/reusable-solidity-docs.yml b/.github/workflows/reusable-solidity-docs.yml index 0771fcc522..b287e3c86c 100644 --- a/.github/workflows/reusable-solidity-docs.yml +++ b/.github/workflows/reusable-solidity-docs.yml @@ -125,7 +125,7 @@ jobs: - uses: actions/setup-node@v4 with: - node-version: "18.15.0" + node-version: "24.11.1" - uses: ./.github/actions/install-yarn-deps with: diff --git a/solidity/ecdsa/Dockerfile b/solidity/ecdsa/Dockerfile index 086cd4c59a..bfe4b9f96d 100644 --- a/solidity/ecdsa/Dockerfile +++ b/solidity/ecdsa/Dockerfile @@ -1,4 +1,4 @@ -FROM node:18-alpine +FROM node:24.11.1-alpine RUN apk add --update --no-cache \ git \ diff --git a/solidity/ecdsa/package.json b/solidity/ecdsa/package.json index e158cefc9b..223effe15f 100644 --- a/solidity/ecdsa/package.json +++ b/solidity/ecdsa/package.json @@ -78,7 +78,7 @@ "@threshold-network/solidity-contracts": "1.3.0-dev.14" }, "engines": { - "node": ">=18.15.0" + "node": ">=24.0.0" }, "resolutions": { "ethereumjs-abi": "npm:0.6.8", diff --git a/solidity/random-beacon/Dockerfile b/solidity/random-beacon/Dockerfile index 164191215d..b6e2d95dcd 100644 --- a/solidity/random-beacon/Dockerfile +++ b/solidity/random-beacon/Dockerfile @@ -1,4 +1,4 @@ -FROM node:18-alpine +FROM node:24.11.1-alpine RUN apk add --update --no-cache \ git \ diff --git a/solidity/random-beacon/package.json b/solidity/random-beacon/package.json index e0df667812..090c15fc08 100644 --- a/solidity/random-beacon/package.json +++ b/solidity/random-beacon/package.json @@ -73,7 +73,7 @@ "typescript": "^4.4.3" }, "engines": { - "node": ">=18.15.0" + "node": ">=24.0.0" }, "resolutions": { "ethereumjs-abi": "npm:0.6.8"