From a2b68f3ce70e693b54a1f9e506b072e864fb288b Mon Sep 17 00:00:00 2001 From: MK Date: Thu, 17 Sep 2026 11:53:33 +0800 Subject: [PATCH 1/3] ci: use Node 24.21.0 for SFW test commands --- .github/workflows/ci.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2b4331e5f4..5c5b8427f4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1339,6 +1339,10 @@ jobs: install-e2e-test-sfw: name: Local CLI `vp install` E2E test (Socket Firewall Free) + env: + # Includes nodejs/node#61999 (first backported in Node 24.20.0). + # Override vp's project pins; sfw's embedded Node runtime is separate. + VP_NODE_VERSION: '24.21.0' needs: - download-previous-rolldown-binaries - build-windows-cli @@ -1421,6 +1425,10 @@ jobs: echo "$HOME/.vite-plus/bin" >> $GITHUB_PATH fi + - name: Prepare Node.js for SFW tests + # Download the selected runtime before entering sfw's proxy. + run: vp env exec node --version + - name: Download sfw run: | set -euo pipefail @@ -1454,6 +1462,7 @@ jobs: VP_INSECURE_TLS: ${{ matrix.vp_insecure_tls }} run: | set -euo pipefail + sfw "${{ matrix.vp_bin }}" env exec node --version # Force the registry-fetch path: install a pinned pnpm globally so # vp downloads it (and therefore traverses sfw) rather than reusing # whatever's preinstalled on the runner. From 047e2d15a092e0b0213e24fa0777f6a4fea9f275 Mon Sep 17 00:00:00 2001 From: MK Date: Thu, 17 Sep 2026 12:05:02 +0800 Subject: [PATCH 2/3] ci: temporarily skip SFW tests on Windows --- .github/workflows/ci.yml | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5c5b8427f4..fa7ab66033 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1347,7 +1347,7 @@ jobs: - download-previous-rolldown-binaries - build-windows-cli # Run if: not a PR (push-to-main / workflow_dispatch), OR PR has 'test: sfw' label. - # Heavy job (3 OSes × real registry traffic) — gated to avoid running on every PR. + # Heavy job (real registry traffic) — gated to avoid running on every PR. if: >- github.event_name != 'pull_request' || contains(github.event.pull_request.labels.*.name, 'test: sfw') @@ -1371,13 +1371,16 @@ jobs: sfw_asset: sfw-free-macos-arm64 vp_bin: vp vp_insecure_tls: '' - - os: namespace-profile-windows-4c-8g - target: x86_64-pc-windows-msvc - sfw_asset: sfw-free-windows-x86_64.exe - # On Windows vp ships as `vp.exe`; sfw spawns its child process - # directly without applying PATHEXT, so the bare `vp` lookup fails. - vp_bin: vp.exe - vp_insecure_tls: '' + # TODO: Re-enable Windows when SFW's embedded Node includes + # https://github.com/nodejs/node/pull/61999 (Node 24.20.0 / 26.7.0). + # SFW 1.15.2 embeds Node 24.9.0 and hits UV_HANDLE_CLOSING at shutdown. + # VP_NODE_VERSION only changes the child runtime, not SFW's runtime. + # - os: namespace-profile-windows-4c-8g + # target: x86_64-pc-windows-msvc + # sfw_asset: sfw-free-windows-x86_64.exe + # # SFW spawns directly without PATHEXT, so use vp.exe on Windows. + # vp_bin: vp.exe + # vp_insecure_tls: '' runs-on: ${{ matrix.os }} steps: - uses: taiki-e/checkout-action@7d1e50e93dc4fb3bba58f85018fadf77898aee8b # v1.4.2 From 893502191fdd3942c5434ecaaafb2ac2341b7ca3 Mon Sep 17 00:00:00 2001 From: MK Date: Thu, 17 Sep 2026 12:12:38 +0800 Subject: [PATCH 3/3] ci: print the Node runtime embedded in SFW --- .github/workflows/ci.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fa7ab66033..897275001d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1447,8 +1447,11 @@ jobs: fi echo "$RUNNER_TEMP/sfw-bin" >> "$GITHUB_PATH" - - name: Verify sfw on PATH - run: sfw --version + - name: Verify sfw and embedded Node versions + run: | + printf '%s\n' 'console.error("SFW embedded Node:", process.version, process.execPath);' \ + > "$RUNNER_TEMP/sfw-node-version.cjs" + NODE_OPTIONS="--require=\"$RUNNER_TEMP/sfw-node-version.cjs\"" sfw --version - name: Run `sfw vp install` against a real repo # TODO(SocketDev/sfw-free#30, SocketDev/sfw-free#43): drop `vp_insecure_tls`