.Net core 8 Project:- java.lang.IllegalStateException: Failed to parse JaCoCo XML report:

Must-share information (formatted with Markdown):

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension):10.6
  • how is SonarQube deployed: Windows Server on prem installation
  • what are you trying to achieve
  • I am trying to get basic code coverage on .net 8 web api project. I am using opencover as the report tool. My CI tool is Azure devops and during analyze stage, JACOCO is looking for sourcelink.json in my .net obj/debug folder which it do not have read access.
  • what have you tried so far to achieve this
  • I have tried to create code coverage and I am successful. But for some reason, I am getting the errors on JACOCO analyzers for .net project. As I understand this is deprecated. And I do not understand why JACOCO is trying to analyze a .net project.

Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

2024-10-04T05:30:09.9124163Z ##[section]Finishing: DotNetCoreCLI
2024-10-04T05:30:09.9150465Z ##[section]Starting: SonarQubeAnalyze
2024-10-04T05:30:09.9154351Z ==============================================================================
2024-10-04T05:30:09.9154499Z Task : Run Code Analysis
2024-10-04T05:30:09.9154587Z Description : Run scanner and upload the results to the SonarQube server.
2024-10-04T05:30:09.9154705Z Version : 6.3.2
2024-10-04T05:30:09.9154794Z Author : sonarsource
2024-10-04T05:30:09.9154922Z Help : This task is not needed for Maven and Gradle projects since the scanner should be run as part of the build.

More Information
2024-10-04T05:30:09.9155418Z ==============================================================================
2024-10-04T05:30:10.7116434Z [command]/usr/bin/dotnet /home/vsts/work/tasks/SonarQubePrepare.3.2/dotnet-sonar-scanner-msbuild/SonarScanner.MSBuild.dll end
2024-10-04T05:30:10.7116915Z SonarScanner for MSBuild 6.2
2024-10-04T05:30:10.7117203Z Using the .NET Core version of the Scanner for MSBuild
2024-10-04T05:30:10.7117593Z Post-processing started.
2024-10-04T05:30:10.7117918Z Calling the SonarScanner CLI

2024-10-04T05:30:12.1106039Z INFO: Scanner configuration file: /home/vsts/work/tasks/SonarQubePrepare_6.3.2/dotnet-sonar-scanner-msbuild/sonar-scanner-5.0.1.3006/conf/sonar-scanner.properties
2024-10-04T05:30:12.1106779Z INFO: Project root configuration file: /home/vsts/work/1/.sonarqube/out/sonar-project.properties
2024-10-04T05:30:12.2482117Z INFO: SonarScanner 5.0.1.3006
2024-10-04T05:30:12.2491610Z INFO: Java 17.0.12 Eclipse Adoptium (64-bit)
2024-10-04T05:30:12.2493190Z INFO: Linux 6.8.0-1014-azure amd64
2024-10-04T05:30:13.6845987Z INFO: User cache: /home/vsts/.sonar/cache
2024-10-04T05:30:19.0102012Z INFO: Analyzing on SonarQube server 10.6.0.92116
2024-10-04T05:30:19.0103106Z INFO: Default locale: “en”, source code encoding: “UTF-8” (analysis is platform dependent)
2024-10-04T05:30:20.8816704Z INFO: Load global settings
2024-10-04T05:30:21.4083300Z INFO: Load global settings (done) | time=527ms
2024-10-04T05:30:21.4333717Z INFO: :Server id _
2024-10-04T05:30:21.4413290Z INFO: Loading required plugins
2024-10-04T05:30:21.4426138Z INFO: Load plugins index
2024-10-04T05:30:21.7233632Z INFO: Load plugins index (done) | time=283ms
2024-10-04T05:30:21.7243624Z INFO: Load/download plugins
2024-10-04T05:30:26.9960259Z INFO: Load/download plugins (done) | time=5272ms
2024-10-04T05:30:27.1230586Z INFO: Loaded core extensions: developer-scanner
2024-10-04T05:30:27.4413779Z INFO: Process project properties
2024-10-04T05:30:27.4707416Z INFO: Process project properties (done) | time=30ms
2024-10-04T05:30:27.4936265Z INFO: Project key: ZZZ-Systems_ZZZ-Custome
2024-10-04T05:30:27.4958231Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers
2024-10-04T05:30:27.4959048Z INFO: Working dir: /home/vsts/work/1/.sonarqube/out/.sonar
2024-10-04T05:30:27.5195702Z INFO: Load project settings for component key: 'ZZZ-Systems_ZZZ-
2024-10-04T05:30:27.7521436Z INFO: Load project settings for component key: 'ZZZ-Systems_ZZZ-Customers
’ (done) | time=233ms
2024-10-04T05:30:27.7787425Z INFO: Load project branches
2024-10-04T05:30:28.0204794Z INFO: Load project branches (done) | time=241ms
2024-10-04T05:30:28.0249687Z INFO: Load branch configuration
2024-10-04T05:30:28.0250380Z INFO: Found manual configuration of branch/PR analysis. Skipping automatic configuration.
2024-10-04T05:30:28.0258294Z INFO: Load branch configuration (done) | time=4ms
2024-10-04T05:30:28.0565385Z INFO: Load quality profiles
2024-10-04T05:30:28.3483560Z INFO: Load quality profiles (done) | time=292ms
2024-10-04T05:30:28.3599827Z INFO: Auto-configuring with CI ‘Azure DevOps’
2024-10-04T05:30:28.3880463Z INFO: Load active rules
2024-10-04T05:30:39.5535960Z INFO: Load active rules (done) | time=11166ms
2024-10-04T05:30:39.5593318Z INFO: Load analysis cache
2024-10-04T05:30:39.7952973Z INFO: Load analysis cache | time=236ms
2024-10-04T05:30:40.0869706Z INFO: Branch name: feature/419_CompanyCode_validation
2024-10-04T05:30:40.7205970Z INFO: Preprocessing files

2024-10-04T05:30:40.7206475Z INFO: 2 languages detected in 35 preprocessed files
2024-10-04T05:30:40.7206762Z INFO: 33 files ignored because of inclusion/exclusion patterns
2024-10-04T05:30:40.7207108Z INFO: 10 files ignored because of scm ignore settings
2024-10-04T05:30:40.7207433Z INFO: Loading plugins for detected languages
2024-10-04T05:30:40.7207671Z INFO: Load/download plugins
2024-10-04T05:30:41.9697308Z INFO: Load/download plugins (done) | time=1559ms
2024-10-04T05:30:42.0936364Z INFO: Executing phase 2 project builders
2024-10-04T05:30:42.1552717Z INFO: Executing phase 2 project builders (done) | time=62ms
2024-10-04T05:30:42.1662353Z INFO: Load project repositories
2024-10-04T05:30:42.4028248Z INFO: Load project repositories (done) | time=238ms
2024-10-04T05:30:42.4187474Z INFO: Indexing files

2024-10-04T05:30:42.4195607Z INFO: Project configuration:
2024-10-04T05:30:42.4204279Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4226687Z INFO: Indexing files of module ‘ZZZ.Customers.Repository’
2024-10-04T05:30:42.4231326Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository
2024-10-04T05:30:42.4240598Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4270275Z INFO: Indexing files of module ‘ZZZ.Customers.Repository’
2024-10-04T05:30:42.4270633Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository
2024-10-04T05:30:42.4270960Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4271331Z INFO: Indexing files of module ‘ZZZ.Customers.WebAPI’
2024-10-04T05:30:42.4271599Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.WebAPI
2024-10-04T05:30:42.4271899Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4276903Z INFO: Indexing files of module ‘ZZZ.Customers.Data’
2024-10-04T05:30:42.4306127Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Data
2024-10-04T05:30:42.4306548Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4307375Z INFO: Indexing files of module ‘ZZZ.Customers.WebAPI’
2024-10-04T05:30:42.4307737Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.WebAPI
2024-10-04T05:30:42.4316990Z INFO: Source paths: Controllers/ContactController.cs, Controllers/CustomerAddress

2024-10-04T05:30:42.4317366Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4731616Z INFO: Indexing files of module ‘ZZZ.Customers.Service’
2024-10-04T05:30:42.4731927Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Service
2024-10-04T05:30:42.4732453Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4733249Z INFO: Indexing files of module ‘ZZZ.Customers.Repository’
2024-10-04T05:30:42.4733765Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository
2024-10-04T05:30:42.4734225Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4734735Z INFO: Indexing files of module ‘ZZZ.Customers.Repository’
2024-10-04T05:30:42.4735309Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository
2024-10-04T05:30:42.4738812Z INFO: Source paths: BaseRepository.cs, ContactRepository.cs, CustomerAddressRepos

2024-10-04T05:30:42.4740868Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4858322Z INFO: Indexing files of module ‘ZZZ.Customers.Service’
2024-10-04T05:30:42.4861167Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Service
2024-10-04T05:30:42.4863794Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4875992Z INFO: Indexing files of module ‘ZZZ.Customers.Data’
2024-10-04T05:30:42.4878935Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Data
2024-10-04T05:30:42.4879492Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4910269Z INFO: Indexing files of module ‘ZZZ.Customers.Data’
2024-10-04T05:30:42.4913037Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Data
2024-10-04T05:30:42.4915852Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4918550Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.4921143Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.4923762Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4924766Z INFO: Indexing files of module ‘ZZZ.Customers.Infrastructure’
2024-10-04T05:30:42.4925316Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Infrastructure
2024-10-04T05:30:42.4928726Z INFO: Source paths: Extensions/CustomerCodeValidationExtension.cs, ServiceRegistr

2024-10-04T05:30:42.4929253Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4965753Z INFO: Indexing files of module ‘ZZZ.Customers.Data’
2024-10-04T05:30:42.4966421Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Data
2024-10-04T05:30:42.4966954Z INFO: Source paths: CustomerDbContext.cs, Entity/Address.cs, Entity/BaseEntity.cs

2024-10-04T05:30:42.4970025Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4970576Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.4973263Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.4973569Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4973925Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.4974191Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.4974488Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.4995969Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5000230Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5001090Z INFO: Source paths: Address.cs, BaseModel.cs, Constants/CustomerAppSettings.cs, C

2024-10-04T05:30:42.5001665Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5002254Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.5002685Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.5003134Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5003636Z INFO: Indexing files of module ‘ZZZ.Customers.Service’
2024-10-04T05:30:42.5004057Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Service
2024-10-04T05:30:42.5005651Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5006016Z INFO: Indexing files of module ‘ZZZ.Customers.Service’
2024-10-04T05:30:42.5006407Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Service
2024-10-04T05:30:42.5006711Z INFO: Source paths: ContactService.cs, CustomerAddressService.cs, CustomerService.cs
2024-10-04T05:30:42.5007022Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5043212Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5046037Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5048654Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5051316Z INFO: Indexing files of module ‘ZZZ.Customers.Service’
2024-10-04T05:30:42.5053888Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Service
2024-10-04T05:30:42.5055798Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5073203Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5098724Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5099052Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5099471Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.5099747Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.5100052Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5100401Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.5100674Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.5100976Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5101317Z INFO: Indexing files of module ‘ZZZ.Customers.Data’
2024-10-04T05:30:42.5101584Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Data
2024-10-04T05:30:42.5101885Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5102242Z INFO: Indexing files of module ‘ZZZ.Customers.Infrastructure’
2024-10-04T05:30:42.5102528Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Infrastructure
2024-10-04T05:30:42.5102847Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5199108Z INFO: Indexing files of module ‘ZZZ.Customers.Repository’
2024-10-04T05:30:42.5210724Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository
2024-10-04T05:30:42.5211099Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5211528Z INFO: Indexing files of module ‘ZZZ.Customers.Data’
2024-10-04T05:30:42.5211795Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Data
2024-10-04T05:30:42.5212444Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5212811Z INFO: Indexing files of module ‘ZZZ.Customers.Infrastructure’
2024-10-04T05:30:42.5213095Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Infrastructure
2024-10-04T05:30:42.5213404Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5213748Z INFO: Indexing files of module ‘ZZZ.Customers.Tests’
2024-10-04T05:30:42.5214016Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Tests
2024-10-04T05:30:42.5214314Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5214663Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.5214935Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.5215460Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5215833Z INFO: Indexing files of module ‘ZZZ.Customers.Infrastructure’
2024-10-04T05:30:42.5220594Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Infrastructure
2024-10-04T05:30:42.5221563Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5221989Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5222260Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5222560Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5231750Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5232211Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5232532Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5234258Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5234816Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5279390Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5306213Z INFO: Indexing files of module ‘ZZZ.Customers.Tests’
2024-10-04T05:30:42.5306539Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Tests
2024-10-04T05:30:42.5306839Z INFO: Test paths: Controllers/ContactControllerTests.cs, Controllers/CustomerAddr

2024-10-04T05:30:42.5307159Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5479554Z INFO: Indexing files of module ‘ZZZ.Customers.Model’
2024-10-04T05:30:42.5480255Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Model
2024-10-04T05:30:42.5480826Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5492146Z INFO: Indexing files of module ‘ZZZ.Customers.Interface’
2024-10-04T05:30:42.5493351Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Interface
2024-10-04T05:30:42.5493971Z INFO: Source paths: Common/IDuplicateValidation.cs, Repository/IContactRepository

2024-10-04T05:30:42.5494504Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5545176Z INFO: Indexing files of module ‘ZZZ.Customers.WebAPI’
2024-10-04T05:30:42.5545745Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.WebAPI
2024-10-04T05:30:42.5546221Z INFO: Source paths: obj/Debug/net8.0/ZZZ.Customers.WebAPI.GlobalUsings.g.cs, obj

2024-10-04T05:30:42.5548800Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5555964Z INFO: Indexing files of module ‘ZZZ-Customers’
2024-10-04T05:30:42.5558771Z INFO: Base dir: /home/vsts/work/1/s/ZZZ.Customers
2024-10-04T05:30:42.5560077Z INFO: Excluded sources: /obj/, */.dll, /ZZZ.Customers.Data//, /ZZZ.Customers.Model//
2024-10-04T05:30:42.5594451Z INFO: 35 files indexed
2024-10-04T05:30:42.5599124Z INFO: Quality profile for cs: Sonar way
2024-10-04T05:30:42.5599597Z INFO: Quality profile for json: Sonar way
2024-10-04T05:30:42.5600222Z INFO: ------------- Run sensors on module ZZZ.Customers.Repository
2024-10-04T05:30:42.6313936Z INFO: Load metrics repository
2024-10-04T05:30:42.8733867Z INFO: Load metrics repository (done) | time=242ms
2024-10-04T05:30:43.5603261Z INFO: Sensor C# Project Type Information [csharp]
2024-10-04T05:30:43.5630212Z INFO: Sensor C# Project Type Information [csharp] (done) | time=3ms
2024-10-04T05:30:43.5660020Z INFO: Sensor C# Analysis Log [csharp]
2024-10-04T05:30:43.5695748Z INFO: Roslyn version: 4.11.0.0
2024-10-04T05:30:43.5696160Z INFO: Language version: CSharp12
2024-10-04T05:30:43.5715638Z INFO: Concurrent execution: enabled
2024-10-04T05:30:43.5716380Z INFO: Sensor C# Analysis Log [csharp] (done) | time=7ms
2024-10-04T05:30:43.5716724Z INFO: Sensor C# Properties [csharp]
2024-10-04T05:30:43.5764661Z INFO: Sensor C# Properties [csharp] (done) | time=1ms
2024-10-04T05:30:43.5766052Z INFO: Sensor JaCoCo XML Report Importer [jacoco]
2024-10-04T05:30:43.5875751Z INFO: Importing 59 report(s). Turn your logs in debug mode in order to see the exhaustive list.
2024-10-04T05:30:43.6837167Z ##[error]ERROR: Coverage report ‘/home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository/obj/Debug/net8.0/ZZZ.Customers.Repository.sourcelink.json’ could not be read/imported. Error: {}
java.lang.IllegalStateException: Failed to parse JaCoCo XML report: /home/vsts/work/1/s/ZZZ.Customers/ZZZ.Customers.Repository/obj/Debug/net8.0/ZZZ.Customers.Repository.sourcelink.json

Hi there, @rakeshar. Welcome to the community!

It seems you are running on Azure DevOps and using the AZDO extension. Could you tell us which version of the extension?
Also, would you mind sharing some more information:

  1. Your (redacted if need be) pipeline?
  2. The logs for the SonarQubePrepare task?

Denis.

Extension version:6.3.2 (Latest)

Prepare task logs

2024-10-04T05:27:25.0732329Z ##[section]Starting: SonarQubePrepare
2024-10-04T05:27:25.0737605Z ==============================================================================
2024-10-04T05:27:25.0737755Z Task : Prepare Analysis Configuration
2024-10-04T05:27:25.0737872Z Description : Prepare SonarQube analysis configuration
2024-10-04T05:27:25.0737985Z Version : 6.3.2
2024-10-04T05:27:25.0738065Z Author : sonarsource
2024-10-04T05:27:25.0738178Z Help : More Information
2024-10-04T05:27:25.0738366Z ==============================================================================
2024-10-04T05:27:26.3314401Z [command]/usr/bin/dotnet /home/vsts/work/tasks/SonarQubePrepare/6.3.2/dotnet-sonar-scanner-msbuild/SonarScanner.MSBuild.dll begin /k:ZZZ-Systems_ZZZ-fc
2024-10-04T05:27:27.6347777Z SonarScanner for MSBuild 6.2
2024-10-04T05:27:27.6349099Z Using the .NET Core version of the Scanner for MSBuild
2024-10-04T05:27:28.5818644Z Pre-processing started.
2024-10-04T05:27:28.5832326Z Preparing working directories

2024-10-04T05:27:29.1423809Z 05:27:29.141 Updating build integration targets

2024-10-04T05:27:30.3859736Z 05:27:30.385 Fetching analysis configuration settings

2024-10-04T05:27:32.3993115Z 05:27:32.398 Provisioning analyzer assemblies for cs

2024-10-04T05:27:32.3996278Z 05:27:32.399 Installing required Roslyn analyzers

2024-10-04T05:27:32.3998475Z 05:27:32.399 Processing plugin: csharp version 9.27.0.93347
2024-10-04T05:27:33.8973977Z 05:27:33.896 Processing plugin: vbnet version 9.27.0.93347
2024-10-04T05:27:34.1550710Z 05:27:34.154 Processing plugin: securitycsharpfrontend version 10.6.0.31509
2024-10-04T05:27:35.0653088Z 05:27:35.064 Provisioning analyzer assemblies for vbnet

2024-10-04T05:27:35.0658290Z 05:27:35.064 Installing required Roslyn analyzers

2024-10-04T05:27:35.0659368Z 05:27:35.064 Processing plugin: csharp version 9.27.0.93347
2024-10-04T05:27:35.0660298Z 05:27:35.065 Processing plugin: vbnet version 9.27.0.93347
2024-10-04T05:27:35.1368619Z 05:27:35.136 Incremental PR analysis: Base branch parameter was not provided.
2024-10-04T05:27:35.1376588Z 05:27:35.136 Cache data is empty. A full analysis will be performed.
2024-10-04T05:27:35.1708391Z 05:27:35.17 Pre-processing succeeded.
2024-10-04T05:27:35.1825942Z ##[section]Finishing: SonarQubePrepare
—PIPELINE BELOW—


trigger:
- develop
- feature/*

resources:
- repo: self
    # Disable shallow fetch
  fetchDepth: 0

variables:
  dockerfilePath: '$(Build.SourcesDirectory)/zzz.Customers/Dockerfile'
  tag: '$(Build.BuildId)'

  vmImageName: 'ubuntu-latest'

stages:
- stage: Build
  displayName: Build and push stage
  jobs:
  - job: Build
    displayName: Build
    pool:
      vmImage: $(vmImageName)
    steps:
    # Prepare Analysis Configuration task
    - task: SonarQubePrepare@6
      inputs:
        SonarQube: 'SonarQubeServiceConnection'
        scannerMode: 'MSBuild'
        projectKey: ''
        projectName: 'zzz-Customers'
    - task: DotNetCoreCLI@2
      inputs:
        command: 'restore'
        projects: '**/*.csproj'
        feedsToUse: 'select'
        vstsFeed: '$FEED'
       - task: DotNetCoreCLI@2
      inputs:
        command: 'test'
        projects: '**/*.Tests.csproj'
        testRunTitle: 'UnitTestsResult'
        arguments: '--collect "Code Coverage"'
           - task: PublishCodeCoverageResults@2
      inputs:
        summaryFileLocation: '$(System.DefaultWorkingDirectory)/**/coverage.cobertura.xml'
        #reportDirectory: '$(System.DefaultWorkingDirectory)/**/coverage'
        failIfCoverageEmpty: true

    - task: SonarQubeAnalyze@6
      inputs:
        jdkversion: 'JAVA_HOME_17_X64'
    - task: SonarQubePublish@6
      inputs:
        pollingTimeoutSec: '300'
    - task: Docker@2
      displayName: Build an image
      inputs:
        command: build
        containerRegistry: $(DOCKER_REGISTRY_SERVICE_CONNECTION)
        repository: $(IMAGE_REPOSITORY)
        dockerfile: $(dockerfilePath)
        tags: |
          $(tag)
          latest
        arguments: --build-arg FEED_ACCESS_USER=$(zzz_NUGET_FEED_ACCESS_USER) --build-arg FEED_ACCESS_TOKEN=$(zzz_NUGET_FEED_PAT_TOKEN)

Hi,

I am not sure what is going on.
Can you try to remove the PublishCodeCoverageResults@2 task, or at least move it after the SonarQubePublish@6 task?
I’d like to make sure this does not interfere with the process.

Moreover, your input to the PublishCodeCoverageResults task seems to indicate a cobertura file format. Please note we do not support that format, as indicated in the docs. That being said, it seems strange to me that the output of the dotnet test command with --collect “Code Coverage” would produce cobertura format, so you might have some other issue there.

Please let us know if the change has any effect.

Denis

Denis, Thank you for the reply. Earlier pipeline, I copied from a different branch though the errors copied was from the develop branch. Here is the pipeline code of develop branch. In this you can see that the publish is after analyze.
Also the coverage tool that we use is opencover as you can see below

# Docker
# Build and push an image to Azure Container Registry
# https://docs.microsoft.com/azure/devops/pipelines/languages/docker


trigger:
- develop
- feature/*

resources:
- repo: self
    # Disable shallow fetch
  fetchDepth: 0

variables:
- group: ZZZ-dev-build-variables  
- name: dockerfilePath
  value: '$(Build.SourcesDirectory)/ZZZ.Customers/Dockerfile'
- name: image-repository
  value: ZZZ-customers
- name: tag
  value: '$(Build.BuildId)'
- name: BuildConfiguration
  value: 'Release'
stages:
- stage: Build
  displayName: Build and push stage
  jobs:
  - job: Build
    displayName: Build
    pool:
      vmImage: $(vmImageName)
    steps:
    # Prepare Analysis Configuration task
    - task: SonarQubePrepare@6
      inputs:
        SonarQube: 'SonarQubeServiceConnection'
        scannerMode: 'MSBuild'
        projectKey: 'ZZZ-Systems_ZZZ-Customers_'
        projectName: 'ZZZ-Customers'
        displayName: 'Prepare analysis on SonarQube'
        extraProperties: |
          sonar.cs.opencover.reportsPaths=$(Agent.TempDirectory)/**/coverage.opencover.xml  
          sonar.exclusions=/obj/,**/.dll*,**/ZZZ.Customers.Data/**/*,**/ZZZ.Customers.Model/**/*           
    - task: DotNetCoreCLI@2
      inputs:
        command: 'restore'
        projects: '**/*.csproj'
        feedsToUse: 'select'
        vstsFeed: ''
    - task: DotNetCoreCLI@2
      displayName: 'Unit Test Coverage'
      inputs:
        command: 'test'
        projects: '**/*Tests/*.csproj'
        arguments: '--collect "XPlat Code Coverage;Format=opencover"'
    - task: DotNetCoreCLI@2
      inputs:
        command: 'build'
        projects: '**/*.csproj'
        arguments: '--configuration $(BuildConfiguration)'
    - task: SonarQubeAnalyze@6
      inputs:
        jdkversion: 'JAVA_HOME_17_X64'
    - task: SonarQubePublish@6
      inputs:
        pollingTimeoutSec: '300'
    - task: Docker@2
      displayName: Build an image
      inputs:
        command: build
        containerRegistry: $(docker-registry-service-connection)
        repository: $(image-repository)
        dockerfile: $(dockerfilePath)
        tags: |
          $(tag)
          latest
        arguments: --build-arg FEED_ACCESS_USER=$(ZZZ-nuget-feed-access-user) --build-arg FEED_ACCESS_TOKEN=$(ZZZ-nuget-feed-pat-token)
    - task: Docker@2
      displayName: Push an image to container registry
      inputs:
        command: push
        containerRegistry: $(docker-registry-service-connection)
        repository: $(image-repository)
        tags: |
          $(tag)
          latest```

Hi @rakeshar

Just to be sure, you do not have anything either in Project Settings > General Settings > JaCoCo or Administration > Configuration > General Settings > JaCoCo?

Denis

1 Like

Denis,
No, I have not put in anything in the Jacoco config


But in Projects setting by default I have this

I removed the two * and ** settings and now the errors are not appearing any more.

Thank you.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.