We have intermittent cases where SonarCloud doesn’t update the GitHub PR status after a successful scan with no warnings. This happens several times a week across different repositories and projects. Is there any way to get more visibility as to why this update never happens?
Additional Information:
- GitHub is code repository
- CI system used: GitHub Actions
- Scanner command used:
- dotnet-sonarscanner begin /key:$SONAR_KEY
/o:"$SONAR_ORGANIZATION"
/d:sonar.host.url="$SONAR_URL"
/d:sonar.login=$SONAR_LOGIN
/d:sonar.cs.opencover.reportsPaths="$CODE_COVERAGE_REPORT_PATH"
/d:sonar.coverage.exclusions="$CODE_COVERAGE_EXCLUSIONS"
/d:sonar.exclusions=$SONAR_EXCLUSIONS
/d:sonar.cpd.exclusions=$SONAR_DUPLICATION_EXCLUSIONS
/d:sonar.pullrequest.base=$GITHUB_BASE_REF
/d:sonar.pullrequest.branch=GITHUB_HEAD_REF \ /d:sonar.pullrequest.key="(echo $GITHUB_REF | cut -d ‘/’ -f 3)" - .NET Build
- dotnet-sonarscanner end /d:sonar.login=$SONAR_LOGIN
- dotnet-sonarscanner begin /key:$SONAR_KEY
- Languages: C# .NET Core projects
- Project/Repo Links: My Sonar projects and GitHub repositories are private so I cannot share them here
- Issue: Across many projects, seemingly randomly, SonarCloud simply fails to update the GitHub PR status. SonarCloud completed the scan successfully without warnings in the UI, but it just never updates the GitHub PR status.
- Reproduce: I have no way to reliably reproduce
- Workaround: requires committing pointless changes to the repo to trigger build and a new SonarCloud scan, hoping that the status updates the next time