LCOV File Not Found: Coverage Data cant able to exported

Hello SonarQube Community,

I am running the SonarScanner CLI to analyze a Node Red project and I am encountering an issue with the coverage report. Despite specifying the LCOV report path in the scanner command, the coverage data is not being imported. Here are the details of my setup and the error:

Command Used:

sonar-scanner
-Dsonar.projectKey=Vnetpops-UI
-Dsonar.sources=.
-Dsonar.host.url=http://localhost:9000
-Dsonar.token=sqp_***************************************
-Dsonar.javascript.lcov.reportPaths=coverage/lcov.info

Error in Logs:

10:07:25.066 INFO No LCOV files were found using coverage/lcov.info
10:07:25.067 WARN No coverage information will be saved because all LCOV files cannot be found.

Expected Behavior:
The coverage data from the lcov.info file should be imported and displayed in the SonarQube dashboard.

Actual Behavior:
The analysis completes successfully, but no coverage data is imported, and the logs indicate that the LCOV file cannot be found.

Any guidance or suggestions to resolve this issue would be greatly appreciated. Thank you in advance for your help!

Best regards,
Dhamodharan

Hi Dhamodharan,

Based on the log lines you’ve shared, analysis doesn’t find a file at the path you’ve provided. So, what is the path to the coverage report?

 
Ann

Hi Ann,Thanks for the reply.
Below attached the project configuration for reference

dhamo@dhamo:~/vnetpops-dev/node-red/vnetpops-ui$ sonar-scanner
12:05:32.799 INFO Scanner configuration file: /opt/sonar-scanner/conf/sonar-scanner.properties
12:05:32.802 INFO Project root configuration file: /home/dhamo/vnetpops-dev/node-red/vnetpops-ui/sonar-project.properties
12:05:32.815 INFO SonarScanner CLI 7.0.2.4839
12:05:32.816 INFO Java 17.0.13 Eclipse Adoptium (64-bit)
12:05:32.817 INFO Linux 5.15.0-131-generic amd64
12:05:32.843 INFO User cache: /home/dhamo/.sonar/cache
12:05:33.484 WARN Use of ‘sonar.login’ property has been deprecated in favor of ‘sonar.token’ (or the env variable alternative ‘SONAR_TOKEN’). Please use the latter when passing a token.
12:05:33.485 INFO JRE provisioning: os[linux], arch[x86_64]
12:05:33.555 INFO Communicating with SonarQube Community Build 25.2.0.102705
12:05:33.821 INFO Starting SonarScanner Engine…
12:05:33.822 INFO Java 17.0.13 Eclipse Adoptium (64-bit)
12:05:34.711 INFO Load global settings
12:05:34.784 INFO Load global settings (done) | time=73ms
12:05:34.788 INFO Server id: 147B411E-AZU2iA_xqQH9cClPV7fK
12:05:34.804 INFO Loading required plugins
12:05:34.805 INFO Load plugins index
12:05:34.820 INFO Load plugins index (done) | time=15ms
12:05:34.820 INFO Load/download plugins
12:05:34.864 INFO Load/download plugins (done) | time=45ms
12:05:35.150 INFO Process project properties
12:05:35.156 ERROR You must define the following mandatory properties for ‘Unknown’: sonar.projectKey
12:05:35.211 INFO EXECUTION FAILURE
12:05:35.212 INFO Total time: 2.414s

Regards
Dhamodharan

Hi Dhamodharan,

That doesn’t answer the question; it poses a new one.

It seems that you failed to provide configuration to the analysis.

 
HTH,
Ann