we are getting this message The main branch has no lines of code. after scanning the azure logicapp code from ADO(main branch) to SonarQube.
How can I fixed this issues?
16/16 source files have been analyzed
2025-04-04T12:19:29.8073864Z INFO: Sensor TextAndSecretsSensor [text] (done) | time=1167ms
2025-04-04T12:19:29.8122042Z INFO: ------------- Run sensors on project
2025-04-04T12:19:29.9865288Z INFO: Sensor Zero Coverage Sensor
2025-04-04T12:19:29.9871329Z INFO: Sensor Zero Coverage Sensor (done) | time=1ms
2025-04-04T12:19:29.9886785Z INFO: ------------- Gather SCA dependencies on project
2025-04-04T12:19:29.9910728Z INFO: SCM Publisher is disabled
2025-04-04T12:19:29.9932532Z INFO: CPD Executor Calculating CPD for 0 files
2025-04-04T12:19:29.9956007Z INFO: CPD Executor CPD calculation finished (done) | time=0ms
2025-04-04T12:19:30.0011519Z INFO: SCM revision ID '’
2025-04-04T12:19:30.1641842Z INFO: Analysis report generated in 158ms, dir size=230.9 kB
2025-04-04T12:19:30.1784985Z INFO: Analysis report compressed in 12ms, zip size=24.0 kB
2025-04-04T12:19:30.2443284Z INFO: Analysis report uploaded in 66ms
2025-04-04T12:19:30.2459659Z INFO: ANALYSIS SUCCESSFUL, you can find the results at: https:///dashboard?id=zmuat-isb-disbursements-uksouth-001
2025-04-04T12:19:30.2476246Z INFO: Note that you will be able to access the updated dashboard once the server has processed the submitted analysis report
2025-04-04T12:19:30.2477229Z INFO: More about the report processing at https:///ce/task?id=818c9ad4-a306-4670-8cce-dfea95057512
2025-04-04T12:19:30.2569711Z INFO: Analysis total time: 4.317
this is the yml file we are using
trigger:
branches:
include:
- main
paths:
include:
- 'zmuat-isb-disbursements-uksouth-001/*'
pool:
vmImage: ubuntu-latest
steps:
- script: echo "Running SonarQube Analysis for zmuat-isb-disbursements-uksouth-001"
displayName: "Start SonarQube - zmuat-isb-disbursements-uksouth-001"
- task: JavaToolInstaller@0
inputs:
versionSpec: "17"
jdkArchitectureOption: "x64" # Specify the architecture (x64 for 64-bit)
jdkSourceOption: "PreInstalled"
# ✅ Prepare SonarQube Analysis Configuration
- task: SonarQubePrepare@5
inputs:
SonarQube: 'zm-sonarqube-service-connection'
scannerMode: CLI
configMode: manual
cliProjectKey: "zmuat-isb-disbursements-uksouth-001"
cliProjectName: "zmuat-isb-disbursements-uksouth-001"
cliSources: "zmuat-isb-disbursements-uksouth-001/LogicApp"
extraProperties: |
sonar.verbose=true
sonar.inclusions=**/*.json
sonar.language=json
# ✅ Run SonarQube Analysis
- task: SonarQubeAnalyze@5
# ✅ Publish SonarQube Results
- task: SonarQubePublish@5
inputs:
pollingTimeoutSec: 800
Do you really only want to analyze JSON files? If not, I would remove these lines.
If your code is only JSON files, you’re going to be out of luck. SonarQube only scans JSON files if they map to a supported language (like Azure Resource Manager templates).
There is any other way to scan the azure logicapp workflows code (written in json file) ?
SonarQube has no specific support for azure logicapp workflows code or expressions.