Node.js update to 12

Hi, bench update kept telling me node.js version should be above 12.
so i updated and now :
Error: You need to install either node-sass or sass in order to process Sass files

Hi,

Try sudo npm install -g sass , then update.

still there

node-sass uses different binaries for each version of nodejs, so you probably need to rebuild. from the app/frappe directory, try something like npm rebuild node-sass. If that doesn’t work, you could try removing and readding (yarn remove node-sass then yarn add node-sass). Confirm your node version first (node -v) to make sure you’ve got 12+.

yeah but the current version on my server is 18.1.0
So I don’t get where the problem is?

It is possible to have multiple versions of node (and node-sass) installed simultaneously, and it looks like the one being called from the bench environment is the wrong one. Path and dependency issues are always very tricky to troubleshoot. Are you doing your testing from within the bench environment? (Accessible via source env/bin/activate)

When updated, you need
cd frappe-bench
bench setup requirements

1 Like

nope, still there.

I don’t understand what you mean by two environments.
I have 1 site installed and 1 frappe, 1 erpnext ,…

Help :smiley:

When you uninstalled and reinstalled node-sass via yarn from the frappe app directory, did you see any output?

Could this be the problem?
what should I do?

If you’d like help from me, can you please respond to this:

Yep
warning package.json: No license field
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
warning No license field

What’s the output of yarn list --pattern node-sass?

just did a clean install, tnx for the help.
there are problems with restore with i post in a new thread.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.