Bitbucket pipeline & sonarcloud-scan pipe on Play/SBT project not showing Jacoco coverage


Im pretty new to the Bitbucket & Sonarcloud integration. We run:

  • Bitbucket Cloud (GIT + Pipelines) , private repo
  • Java project with Play Framework (2.7) in multi-module setup,
  • build via SBT version 1.2.8
  • Jacoco via SBT-jacoco plugin producing XML reports before sonarcloud run
  • we followed the Bitbucket howto on: . invocation in bitbucket-pipelines.xml is:
    • pipe: sonarsource/sonarcloud-scan:1.0.1
                    EXTRA_ARGS: '$BITBUCKET_BRANCH -Dsonar.projectVersion=$version'
                    SONAR_SCANNER_OPTS: -Xmx1024m
                    DEBUG: "true"

  • On SonarCloud we have a paid private account and I see the scan results of each pipeline run. However I dont see any non-empty code coverage results from Jacoco.
  • I see in the pipeline logs that the “Sensor JaCoCo XML Report Importer” has successfully run:
16:29:42.697 DEBUG: Download plugin 'jacoco' to '/root/.sonar/_tmp/fileCache7886833387702394198.tmp'
16:29:42.791 DEBUG: GET 200 | time=93ms
16:29:42.792 DEBUG: Unpacking plugin jacoco
16:30:15.281 DEBUG: Sensors : JavaSquidSensor -> SonarCSS Rules -> Scala Sensor -> SurefireSensor -> JavaXmlSensor -> HTML -> XML Sensor -> JaCoCo XML Report Importer -> JavaSecuritySensor -> CSharpSecuritySensor -> PhpSecuritySensor -> PythonSecuritySensor
16:33:38.859 INFO: Sensor JaCoCo XML Report Importer [jacoco]
16:33:38.859 INFO: 1/1 source files have been analyzed
16:33:38.867 DEBUG: Reading report '/opt/atlassian/pipelines/agent/build/modules/xxxx/target/scala-2.12/jacoco/report/jacoco.xml'
16:33:39.118 INFO: Sensor JaCoCo XML Report Importer [jacoco] (done) | time=259ms

The sonarcloud UI is also a bit confusing, but I think I looked everywhere.

Any help is appreciated,

Update: Issue is solved - we experimented all this on a feature branch only, which is considered a “short lived branch”. Once we run it on develop & master , SonarCloud magically shows much more coverage details.