Skip to content

Commit 1d2ead0

Browse files
committed
Update to Node v16.16
This brings us back onto an active LTS release. Notably it also seems to handle HTTP/2 in a way that doesn't trip CloudFlare's fingerprint detection in many cases. Updates win-version-info along the way (both locally & transitively in browser-launcher) because old releases don't include prebuilds for Node 16. Needs a workaround en route due to the switch to prebuildify, which builds (via node-gyp-build) for the real platform, not the target platform. Hackily solved for now, but may need work later.
1 parent debd206 commit 1d2ead0

File tree

4 files changed

+167
-680
lines changed

4 files changed

+167
-680
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616

1717
- uses: actions/setup-node@v1
1818
with:
19-
node-version: 14.18.3
19+
node-version: 16.16.0
2020

2121
- run: npm install -g npm@^8
2222

build-release.sh

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@ export npm_config_platform=$TARGET_PLATFORM
2727
# Pick the target platform for node-pre-gyp:
2828
export npm_config_target_platform=$TARGET_PLATFORM
2929

30+
# Disable node-gyp-build for win-version-info only. Without this, it's
31+
# rebuilt for Linux, even given $TARGET_PLATFORM=win32, and then breaks
32+
# at runtime even though there are valid win32 prebuilds available.
33+
export WIN_VERSION_INFO=disable-prebuild
34+
3035
TARGET=$TARGET_PLATFORM-$TARGET_ARCH
3136

3237
# ------------------------------------------------------------------------
@@ -60,17 +65,19 @@ PACKAGE_WHITELIST=''
6065
case "$TARGET_PLATFORM" in
6166
linux)
6267
EXPECTED_BIN_STRING="ELF"
63-
# Builds raw on non-Windows, but never used
64-
PACKAGE_WHITELIST="registry-js"
68+
# Registry-js builds raw on non-Windows, but never used
69+
# Win-version info includes prebuilds for Windows on all platforms
70+
PACKAGE_WHITELIST="registry-js|win-version-info/prebuilds"
6571
;;
6672
win32)
6773
EXPECTED_BIN_STRING="MS Windows"
6874
PACKAGE_WHITELIST=""
6975
;;
7076
darwin)
7177
EXPECTED_BIN_STRING="Mach-O"
72-
# Builds raw on non-Windows, but never used
73-
PACKAGE_WHITELIST="registry-js"
78+
# Registry-js builds raw on non-Windows, but never used
79+
# Win-version info includes prebuilds for Windows on all platforms
80+
PACKAGE_WHITELIST="registry-js|win-version-info/prebuilds"
7481
;;
7582
*)
7683
echo "Unknown platform $TARGET_PLATFORM"

0 commit comments

Comments
 (0)