[hermes] bstein-dev-home #540: sonarqube_scan_missing_nodejs #43

Open
opened 2026-09-20 21:40:22 +00:00 by hermes-automation · 0 comments

Hermes auto-triage classified incident bstein-dev-home/540 as sonarqube_scan_missing_nodejs (confidence 0.7); first failed gate: sonarqube.

Why a human is needed

The pipeline failed in the 'Publish test metrics' stage, not in your application code or tests. Backend pytest already passed (128 passed) before this point, and the build published no structured test failures at all, so the test suites themselves are clean for this run. The actual break is in the quality-scan step: SonarQube's scanner tried to run its JavaScript/TypeScript analyzer and errored out because it could not find a Node.js executable ('Error when running: node -v. Is Node.js available during analysis?', then the underlying cause 'Cannot run program "node": error=2, No such file or directory'). That's a tooling/environment gap in whatever stage or container runs the sonar-scanner, not a defect in your source. After that failure the pipeline skipped 'Build & push backend' and exited with code 1. Fixing this means making a working Node.js binary available wherever the SonarQube scan actually executes -- either add Node.js to that stage's image/container, point the scanner at an existing Node install via its executable-path setting, or scope the analysis so it doesn't attempt JS/TS analysis in an environment that has no Node.js runtime. Note the log-correlation lookup for this window also failed (connection refused to the log backend), so there's no independent log trail beyond the retained console output to corroborate further.

Ariadne did not authorize automated remediation: classification_not_supported: 'sonarqube_scan_missing_nodejs'.

Facts

  • jenkins — Jenkins job bstein-dev-home build #540 finished with result FAILURE (start 2026-09-20T21:26:00.647Z, end 2026-09-20T21:36:30.015Z). (jenkins.result, jenkins.timestamps, https://ci.bstein.dev/job/bstein-dev-home/540/)
  • jenkins — The build reports 'Publish test metrics' as the first failed pipeline stage. (jenkins.first_failed_stage)
  • jenkins — No structured test failures were published for this build (failed_tests is an empty list). (jenkins.failed_tests)
  • jenkins — The chronologically earliest console failure excerpt (line 322) shows the SonarQube scanner's JavaScript analyzer sensor throwing org.sonarsource.nodejs.NodeCommandException: 'Error when running: node -v. Is Node.js available during analysis?' (jenkins.console_failures[0], line_number 322)
  • jenkins — The next console excerpt (line 358) shows the same exception's cause: java.io.IOException: Cannot run program "node": error=2, No such file or directory. (jenkins.console_failures[1], line_number 358)
  • jenkins — A later console excerpt (line 682) shows the backend Python suite passed ('128 passed in 5.43s', backend_rc=0) and the pipeline had already moved into the Frontend tests stage (npm install) after that point. (jenkins.console_failures[2], line_number 682)
  • jenkins — The console tail shows the 'Build & push backend' stage was skipped due to earlier failure(s), and the pipeline ended with 'ERROR: script returned exit code 1' and 'Finished: FAILURE'. (jenkins.console_tail)
  • opensearch — OpenSearch log correlation for this incident's time window returned no records because the request failed with a connection error. (log_evidence.error: 'opensearch request failed: [Errno 111] Connection refused')

Evidence

The earliest failure region of the build console:

21:29:17.307 INFO  Sensor JaCoCo XML Report Importer [jacoco] (done) | time=4ms
21:29:17.307 INFO  Sensor IaC CloudFormation Sensor [iac]
21:29:17.420 INFO  0 source files to be analyzed
21:29:17.493 INFO  0/0 source files have been analyzed
21:29:17.493 INFO  Sensor IaC CloudFormation Sensor [iac] (done) | time=186ms
21:29:17.494 INFO  Sensor IaC Kubernetes Sensor [iac]
21:29:17.531 INFO  0 source files to be analyzed
21:29:17.600 INFO  0/0 source files have been analyzed
21:29:17.600 INFO  Sensor IaC Kubernetes Sensor [iac] (done) | time=106ms
21:29:17.600 INFO  Sensor JavaScript analysis [javascript]
21:29:21.789 ERROR Error when running: 'node -v'. Is Node.js available during analysis?
org.sonarsource.nodejs.NodeCommandException: Error when running: 'node -v'. Is Node.js available during analysis?
	at org.sonarsource.nodejs.NodeCommand.start(NodeCommand.java:79)
	at org.sonarsource.nodejs.NodeCommandBuilderImpl.getVersion(NodeCommandBuilderImpl.java:203)
	at org.sonarsource.nodejs.NodeCommandBuilderImpl.checkNodeCompatibility(NodeCommandBuilderImpl.java:169)
	at org.sonarsource.nodejs.NodeCommandBuilderImpl.build(NodeCommandBuilderImpl.java:143)
	at org.sonar.plugins.javascript
... (truncated; the full log is in the linked build)

Inferences

  • The SonarQube analyzer's JavaScript/TypeScript sensor could not locate a working Node.js executable in the environment where the scan ran, and this is the most likely reason the 'Publish test metrics' stage failed and the pipeline exited 1.
  • Because failed_tests is empty and the backend pytest run passed (128 passed) before the frontend stage even started, the application's own test suites are not implicated in this failure; this looks like a gap in the scanning environment's tooling rather than a code or test regression.
  • The stage that runs sonar-scanner (whatever container/image or step that is) appears to be missing a Node.js installation, or Node.js exists but isn't on PATH / at the location sonar-scanner expects, causing the scanner to abort that portion of analysis with a non-zero result that then failed the...
  • Console truncation and the OpenSearch connection failure mean we don't have the full scanner output or independent log confirmation, so it's possible (though less likely given the direct exception trace) that something after this excerpt also contributed to the final exit code.

Suggested remediation (not available)

No automated remediation exists for this failure. Hermes proposes one; it was not performed, and Ariadne cannot perform it until a person builds and deploys it.

  • Proposed action: provision_nodejs_for_sonar_scan
  • What it would do: Ensure a Node.js runtime is installed and on PATH in whatever environment executes the sonar-scanner step (add Node.js to that stage's container/agent image, or point sonar-scanner at an existing Node binary via the sonar.nodejs.executablePath property), then re-run the scan stage.
  • Evidence that should be required first: Sonar-scanner console output showing a NodeCommandException / 'Cannot run program "node": No such file or directory' (or an equivalent 'node not found' error) from the JavaScript/TypeScript sensor, confirming Node.js is genuinely absent from that execution environment rather than a transient timeout or unrelated scanner error.

Filed automatically by Ariadne from a Hermes Agent diagnosis (run run_18817125a2e344c186bcf3ecfb524e05). Hermes has no write access to this repository; no files or infrastructure were changed.

Hermes auto-triage classified incident `bstein-dev-home/540` as **sonarqube_scan_missing_nodejs** (confidence 0.7); first failed gate: `sonarqube`. ## Why a human is needed The pipeline failed in the 'Publish test metrics' stage, not in your application code or tests. Backend pytest already passed (128 passed) before this point, and the build published no structured test failures at all, so the test suites themselves are clean for this run. The actual break is in the quality-scan step: SonarQube's scanner tried to run its JavaScript/TypeScript analyzer and errored out because it could not find a Node.js executable ('Error when running: node -v. Is Node.js available during analysis?', then the underlying cause 'Cannot run program "node": error=2, No such file or directory'). That's a tooling/environment gap in whatever stage or container runs the sonar-scanner, not a defect in your source. After that failure the pipeline skipped 'Build & push backend' and exited with code 1. Fixing this means making a working Node.js binary available wherever the SonarQube scan actually executes -- either add Node.js to that stage's image/container, point the scanner at an existing Node install via its executable-path setting, or scope the analysis so it doesn't attempt JS/TS analysis in an environment that has no Node.js runtime. Note the log-correlation lookup for this window also failed (connection refused to the log backend), so there's no independent log trail beyond the retained console output to corroborate further. Ariadne did not authorize automated remediation: `classification_not_supported: 'sonarqube_scan_missing_nodejs'`. ## Facts - **jenkins** — Jenkins job bstein-dev-home build #540 finished with result FAILURE (start 2026-09-20T21:26:00.647Z, end 2026-09-20T21:36:30.015Z). (`jenkins.result, jenkins.timestamps, https://ci.bstein.dev/job/bstein-dev-home/540/`) - **jenkins** — The build reports 'Publish test metrics' as the first failed pipeline stage. (`jenkins.first_failed_stage`) - **jenkins** — No structured test failures were published for this build (failed_tests is an empty list). (`jenkins.failed_tests`) - **jenkins** — The chronologically earliest console failure excerpt (line 322) shows the SonarQube scanner's JavaScript analyzer sensor throwing org.sonarsource.nodejs.NodeCommandException: 'Error when running: node -v. Is Node.js available during analysis?' (`jenkins.console_failures[0], line_number 322`) - **jenkins** — The next console excerpt (line 358) shows the same exception's cause: java.io.IOException: Cannot run program "node": error=2, No such file or directory. (`jenkins.console_failures[1], line_number 358`) - **jenkins** — A later console excerpt (line 682) shows the backend Python suite passed ('128 passed in 5.43s', backend_rc=0) and the pipeline had already moved into the Frontend tests stage (npm install) after that point. (`jenkins.console_failures[2], line_number 682`) - **jenkins** — The console tail shows the 'Build & push backend' stage was skipped due to earlier failure(s), and the pipeline ended with 'ERROR: script returned exit code 1' and 'Finished: FAILURE'. (`jenkins.console_tail`) - **opensearch** — OpenSearch log correlation for this incident's time window returned no records because the request failed with a connection error. (`log_evidence.error: 'opensearch request failed: [Errno 111] Connection refused'`) ## Evidence The earliest failure region of the build console: ``` 21:29:17.307 INFO Sensor JaCoCo XML Report Importer [jacoco] (done) | time=4ms 21:29:17.307 INFO Sensor IaC CloudFormation Sensor [iac] 21:29:17.420 INFO 0 source files to be analyzed 21:29:17.493 INFO 0/0 source files have been analyzed 21:29:17.493 INFO Sensor IaC CloudFormation Sensor [iac] (done) | time=186ms 21:29:17.494 INFO Sensor IaC Kubernetes Sensor [iac] 21:29:17.531 INFO 0 source files to be analyzed 21:29:17.600 INFO 0/0 source files have been analyzed 21:29:17.600 INFO Sensor IaC Kubernetes Sensor [iac] (done) | time=106ms 21:29:17.600 INFO Sensor JavaScript analysis [javascript] 21:29:21.789 ERROR Error when running: 'node -v'. Is Node.js available during analysis? org.sonarsource.nodejs.NodeCommandException: Error when running: 'node -v'. Is Node.js available during analysis? at org.sonarsource.nodejs.NodeCommand.start(NodeCommand.java:79) at org.sonarsource.nodejs.NodeCommandBuilderImpl.getVersion(NodeCommandBuilderImpl.java:203) at org.sonarsource.nodejs.NodeCommandBuilderImpl.checkNodeCompatibility(NodeCommandBuilderImpl.java:169) at org.sonarsource.nodejs.NodeCommandBuilderImpl.build(NodeCommandBuilderImpl.java:143) at org.sonar.plugins.javascript ... (truncated; the full log is in the linked build) ``` ## Inferences - The SonarQube analyzer's JavaScript/TypeScript sensor could not locate a working Node.js executable in the environment where the scan ran, and this is the most likely reason the 'Publish test metrics' stage failed and the pipeline exited 1. - Because failed_tests is empty and the backend pytest run passed (128 passed) before the frontend stage even started, the application's own test suites are not implicated in this failure; this looks like a gap in the scanning environment's tooling rather than a code or test regression. - The stage that runs sonar-scanner (whatever container/image or step that is) appears to be missing a Node.js installation, or Node.js exists but isn't on PATH / at the location sonar-scanner expects, causing the scanner to abort that portion of analysis with a non-zero result that then failed the... - Console truncation and the OpenSearch connection failure mean we don't have the full scanner output or independent log confirmation, so it's possible (though less likely given the direct exception trace) that something after this excerpt also contributed to the final exit code. ## Suggested remediation (not available) No automated remediation exists for this failure. Hermes proposes one; it was not performed, and Ariadne cannot perform it until a person builds and deploys it. - Proposed action: `provision_nodejs_for_sonar_scan` - What it would do: Ensure a Node.js runtime is installed and on PATH in whatever environment executes the sonar-scanner step (add Node.js to that stage's container/agent image, or point sonar-scanner at an existing Node binary via the sonar.nodejs.executablePath property), then re-run the scan stage. - Evidence that should be required first: Sonar-scanner console output showing a NodeCommandException / 'Cannot run program "node": No such file or directory' (or an equivalent 'node not found' error) from the JavaScript/TypeScript sensor, confirming Node.js is genuinely absent from that execution environment rather than a transient timeout or unrelated scanner error. ## Links - Failed build: https://ci.bstein.dev/job/bstein-dev-home/540/ - Full evidence bundle and audit trail live in Ariadne at `/api/admin/audit/events`, event types `hermes_autotriage_incident` and `hermes_autotriage_diagnosis`. Filed automatically by Ariadne from a Hermes Agent diagnosis (run [run_18817125a2e344c186bcf3ecfb524e05](https://triage.bstein.dev/chat?resume=run_18817125a2e344c186bcf3ecfb524e05)). Hermes has no write access to this repository; no files or infrastructure were changed. <!-- hermes-triage job=bstein-dev-home classification=sonarqube_scan_missing_nodejs incident=bstein-dev-home/540 -->
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: bstein/bstein-dev-home#43
No description provided.