sonarCSS: FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory

Running a gradle build of a large web app project. gradle sonarqube fails and shows a command line and suggests running it separately to debug the problem. When run separately after a couple of minutes the error becomes apparent:

FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory

Failing command seems to be running node to run the stylelint css scanner. If the command is altered to add option:

–max-old-space-size=6000

Then the command succeeds on the command line!

Now how to get Sonarqube running via Gradle to add that option to the node command for sonarCSS?

Running v1.0.2 of the sonarCSS on 64-bit Linux.

Alternatively: how do I disable sonarCSS for this project for now?

Sorry, version of sonarCSS was 1.0.1 for the above. Now actually upgraded to 1.0.2 and get a more direct error message out of the gradle sonarqube command:

FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
1: node::Abort() [stylelint]
2: 0x8c21ec [stylelint]
3: v8::Utils::ReportOOMFailure(char const*, bool) [stylelint]
4: v8::internal::V8::FatalProcessOutOfMemory(char const*, bool) [stylelint]
5: v8::internal::factory::NewRawTwoByteString(int, v8::internal::PretenureFlag) [stylelint]

hello,

indeed it seems that Node.js is failing to allocate enough memory for css analysis. Currently there is no option to modify the arguments of Node.js process which is launched. However you shouldn’t need so much memory usually, what kind of css files are you analysing? You should exclude any generated or minified code