We started getting an error in our pipelines today:
ERROR: Unsupported Node.JS version detected 18.17. Please upgrade to the latest Node.JS LTS version.
org.sonar.plugins.javascript.nodejs.NodeCommandException: Unsupported Node.JS version detected 18.17. Please upgrade to the latest Node.JS LTS version.
We are also facing this issue, but we don’t have the self-hosted sonar. We are using the SonarCube. Does anyone have any information on this? Is it really deprecated or it is a bug?
We expericed the same error in my team, the runner is a self hosted docker, based on image node:20-bookworm, when we log the node version just before the sonar scan, the version is node 20, so it’s probably because the sonar task come with an embeded nodejs.
I think you should fix the sonar scan task (we use SonarSource/sonarcloud-github-action@master).
I am trying to figure out where the problem might be. Github action is using our sonar-scanner-cli docker image 5.0.1, which contains Node.JS 18.17.1 , which should work fine with the analyzer.
Can you pls double check you don’t have some sort of cache and so you are actually not using the latest image?