This doesn’t have anything to do with Yarn, I think. What’s happening is that GitHub Actions is using the latest NodeJS 16 by default but your project’s package.json is only compatible with NodeJS between 10 and 14. You can do one of two things:
Either:
Update your package.json file to also accept 16.
Or:
Update the workflow file created by Cleavr in your repo to add the following step:
You can view the Node version in server > services section. Also, checking the heartbeat will show versions of some other services as well:
Are you asking if you can have multiple versions of Node running and have an app assigned to use one of them? If so - this is something we’ve tried to allow for in the past but didn’t have any luck. We plan on looking at other ways to allow for it.
Actually i was thinking of handling this cleavr-side.
So that when cleavr is creating an GHA-Script it checks for the node version on which the process is/should be running so that the appropriate script will be checked into git.
Would be awesome as it does not require us to change the node version manually in the GHA-Script everytime we set up a deployment.
And thanks for your suggestion, it has already been implemented and is currently going through the QA. You can expect this to go live either today or tomorrow. I’ll let you know once it is deployed.
Cleavr will check for the yarn.lock file during deployments and will use yarn over npm. I think we have an opportunity for improvement to make somewhere so that is more clear.
I was a hardcore Yarn user as well but, thanks to Yarn pushing for it, npm’s performance has significantly improved - in some cases it even defeats Yarn . If you have the lock file checked in, which you should, the performance advantage is very negligible.
One big advantage of npm is that it is the standard and very stable.
There is a new kid on the block - pnpm, which actually brings significant speed improvements. We might support this down the road. But again, how long before npm actually integrates some of the concepts introduced by pnpm and catch up with the speed?
I can then stick with npm without being ”an anti future guy”
I use two frameworks
Quasar for frontend and they have their own CLI but are saying under Getting started ”An App Extension is an npm package.” So I feel comfortable to use npm ”all the way”
Adonis for backend and the say under Creating a new project "You can create a new project using npm init , yarn create or pnpm create.” So I guess Virk don’t mind npm.