R
Railway10mo ago
gustav

Nodejs 20 not set in railway

I have set in my package.json: "engines" : { "node": "20" } and the I have set the NIXPACKS_NODE_VERSION=20 in my environment variables, but still my build fails with: The engine "node" is incompatible with this module. Expected version "20". Got "18.18.2"
27 Replies
Percy
Percy10mo ago
Project ID: 8bd8efef-3533-45db-9b74-4e2772fc4d44
gustav
gustav10mo ago
8bd8efef-3533-45db-9b74-4e2772fc4d44
Brody
Brody10mo ago
maybe you have 18 in an .nvmrc file?
gustav
gustav10mo ago
i don't have a .nvmrc file in my project
Brody
Brody10mo ago
gotcha, can you send a screenshot of the build table at the top of the build logs?
gustav
gustav10mo ago
Thank you for helping. This?
No description
Brody
Brody10mo ago
well yes but can i see the actual logs please, the build table at the of the log lines
gustav
gustav10mo ago
No description
Brody
Brody10mo ago
top of the logs please
gustav
gustav10mo ago
No description
Brody
Brody10mo ago
can you share your repo, there is some strange stuff going on with that table
gustav
gustav10mo ago
No description
gustav
gustav10mo ago
can I share it with your github acc. ?
Brody
Brody10mo ago
delete that file, you theoretically don't need it
gustav
gustav10mo ago
okay, I will try to push again
gustav
gustav10mo ago
now the table cahnged in the top:
No description
gustav
gustav10mo ago
thank you it managed to build now
Brody
Brody10mo ago
awesome, do you use npm or yarn locally?
gustav
gustav10mo ago
yarn how can I make it use yarn?
Brody
Brody10mo ago
do you have a yarn lock file?
gustav
gustav10mo ago
yes
Brody
Brody10mo ago
do you have a package lock file?
gustav
gustav10mo ago
yes
Brody
Brody10mo ago
then delete the package lock file, that's an npm thing
gustav
gustav10mo ago
yes
Brody
Brody10mo ago
once deleted the build on railway should use yarn
gustav
gustav10mo ago
okay, will try, thank you
Want results from more Discord servers?
Add your server