forked from segmentio/typewriter
-
Notifications
You must be signed in to change notification settings - Fork 2
Closed
Description
RudderTyper fails with the following error when running under Node 22, which now in Active LTS status:
[...]/node_modules/rudder-typer/src/cli/index.js:18
import packageJson from '../../package.json' assert { type: 'json' };
^^^^^^
SyntaxError: Unexpected identifier 'assert'
at compileSourceTextModule (node:internal/modules/esm/utils:340:16)
at ModuleLoader.moduleStrategy (node:internal/modules/esm/translators:102:18)
at #translate (node:internal/modules/esm/loader:433:12)
at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:480:27)
at async ModuleJob._link (node:internal/modules/esm/module_job:112:19)
Node.js v22.11.0
Process finished with exit code 1
That is because assert
support has been removed from Node in favour of with
that is based on a more recent version of Import Attributes proposal.
If I manually change all the assert
keywords to with
, everything works as expected.
akashrpo
Metadata
Metadata
Assignees
Labels
No labels