From c08ec7d87fc7c0d04c938da47c9f1c1d59a7ec04 Mon Sep 17 00:00:00 2001 From: Spotandjake Date: Thu, 21 Nov 2024 11:43:40 -0500 Subject: [PATCH] feat(cli): Support node v23 --- cli/bin/grainrun.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cli/bin/grainrun.js b/cli/bin/grainrun.js index 8532637ff..2775c3acc 100644 --- a/cli/bin/grainrun.js +++ b/cli/bin/grainrun.js @@ -10,7 +10,11 @@ const v8 = require("v8"); * * This seems to work for our needs with Node 18, but we should be cautious when updating. */ -v8.setFlagsFromString("--experimental-wasm-return-call"); +if ( + !process.versions.node.startsWith("22.") && + !process.versions.node.startsWith("23.") +) + v8.setFlagsFromString("--experimental-wasm-return-call"); const { readFile } = require("fs/promises"); const { WASI } = require("wasi");