-
Notifications
You must be signed in to change notification settings - Fork 29
Closed
Description
Describe the bug
A SyntaxError appears when trying to run dappnodesdk on Node v22:
file:///home/dappno/.nvm/versions/v22.14.10/lib/node_modules/@dappnode/dappnodesdk/dist/tasks/generatePublishTxs/index.js:8
import registryAbi from "../../contracts/ApmRegistryAbi.json" assert { type: "json" };
^^^^^^
SyntaxError; Unexpected identifier 'assert'
at compileSourceTextModule (node:internal/modules/esm/utils:338:16)
at ModuleLoader.moduleStrategy (node:internal/modules/esm/translators:102:18)
at #translate (node:internal/modules/esm/loader:468:12)
at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:515:27)
This is due to an "import assertion", a feature of Node v16 and v17 which was marked as experimental then and replaced with "import attributes" in v18. The functionality has been deprecated for a long time and was removed in Node v22.
To Reproduce
nvm use 22
npx @dappnode/dappnodesdk -h
Expected behavior
The help menu is shown.
Screenshots
DAppNode version: (SDK version) 0.3.35
(Does not depend on these, didn't even get to starting dappnode)
- Package version:
- OS:
- Browser
Additional context
Metadata
Metadata
Assignees
Labels
No labels