trufflesuite / ganache

:warning: The Truffle Suite is being sunset. For information on ongoing support, migration options and FAQs, visit the Consensys blog. Thank you for all the support over the years.
https://consensys.io/blog/consensys-announces-the-sunset-of-truffle-and-ganache-and-new-hardhat?utm_source=github&utm_medium=referral&utm_campaign=2023_Sep_truffle-sunset-2023_announcement_
MIT License
2.62k stars 679 forks source link

"This version of µWS is not compatible with your Node.js build:" this shows while using " truffle migrate" #4408

Open gha1ish opened 1 year ago

gha1ish commented 1 year ago

apple@Apples-MacBook-Pro web % truffle migrate This version of µWS is not compatible with your Node.js build:

Error: Cannot find module '../binaries/uws_darwin_x64_115.node' Require stack:

ElRoroStupido commented 1 year ago

hello I'm on windows and got the exact same error while trying to use 'truffle migrate --network development' 'truffle test' and even at ganache launch. I get Error: Cannot find module '../binaries/uws_win32_x64_115.node' and he says the exact same files as you are required but i verified and they are where that have to be.

there is even a confusion with the chain id . when launching ganache I get chain id 1337, and this is what I write in the truffle-config.js file. BUT somehow when I try to migrate/ compile it says that the chain id is some weird number such as "1684846497257"

well, searching on google doesn't help it's like that 115. node never existed lol

davidmurdoch commented 1 year ago

115 is the node module version for Node 20. We don't fully support Node 20 yet (everything works perfectly, but uWS isn't used for the http server -- hence the warning message "falling back to a NodeJS implementation").

1684846497257 is the network id, not the chain id.

ElRoroStupido commented 1 year ago

So, does it mean I should use some previous node version ? Or does it changes nothing ? And, when I run ganache I know I'm maybe dumb but I can't find where the network id is written

davidmurdoch commented 1 year ago

Use Node v18 until we support Node 20.

The network id is randomized on start up. In your truffle config you can use * to mean "any network id", or you can specify the --chain.networkId=1337 if you'd prefer.

ElRoroStupido commented 1 year ago

Thanks a lot for your help, i'll do that