Bitbucket non master branches don't work

Template for a good new topic, formatted with Markdown:

  • ALM used (Bitbucket Cloud)
  • CI system used (Bitbucket Cloud
  • Scanner command used when applicable (private details masked)
  • Languages of the repository C#

We are trying to get sonarcloud to work with our bitbucket. But it will only work with the master branch.
If i use another branch is seems to not work properly. Either it doesn’t analyse it or it won’t build or it reports no lines of code then sends a lovely you have zero bugs. We obviously, with no code there can’t be any errors.

We don’t use the “master” branch at all in bitbucket, instead we use release\development and release\production

All i’m trying to do is get sonarcloud to analyse code published to our release\development branch and report this back to bitbucket and also have it visible on the sonarcloud dashboard.

I’m fairly confident our sonarcloud is simply not working so i’m not confident in any of the reports its giving.

I’ve spent hours going through the manual for everything from branches to quality gates and new code settings but can’t seem to figure out anything logical going on so now extremely confused

This is the yml file in bitbucket

image: atlassian/default-image:2 # Choose an image matching your project needs
  depth: full              # SonarCloud scanner needs the full history to assign issues properly

      memory: 2048
    sonar: ~/.sonar/cache  # Caching SonarCloud artifacts will speed up your build
    - step: &build-test-sonarcloud
        name: Build, test and analyze on SonarCloud
          - sonar
          - pipe: sonarsource/sonarcloud-scan:1.0.1
              SONAR_TOKEN: ${SONAR_TOKEN}
              EXTRA_ARGS: '-Dsonar.organization=atomatedev -Dsonar.projectKey=atomatedev_baw-in-aps -Dsonar.exclusions="**/*.xml,**/*.css,**/*.web,**/*.js"'
              SONAR_SCANNER_OPTS: -Xmx512m
          - pipe: sonarsource/sonarcloud-quality-gate:0.1.3
pipelines:                 # More info here:
      - step: *build-test-sonarcloud
      - step: *build-test-sonarcloud