latticexyz / mud

MUD is a framework for building autonomous worlds
https://mud.dev
MIT License
725 stars 183 forks source link

CLI doesn't work with node v22 #2790

Open smallbraingames opened 5 months ago

smallbraingames commented 5 months ago

Hello MUD friendos,

Cli doesn't work with node v22. Pretty sure its this because the error goes away if I switch back to node v 21

Specifically on mud build I get this error

SyntaxError: Unexpected identifier 'assert'
    at compileSourceTextModule (node:internal/modules/esm/utils:337:16)
    at ModuleLoader.moduleStrategy (node:internal/modules/esm/translators:166:18)
    at callTranslator (node:internal/modules/esm/loader:416:14)
    at ModuleLoader.moduleProvider (node:internal/modules/esm/loader:422:30)
    at async link (node:internal/modules/esm/module_job:88:21)

And I think it is related to the use of assert and them removing support for it (see here: https://nodejs.org/en/blog/release/v22.0.0)

Not an urgent annoyance, just an annoyance