It should not be a warning when failing to publish github results when master

  • which versions are you using (SonarQube 9.4.0-DE, dockerized)
  • what are you trying to achieve
    Analysis of master branch
  • what have you tried so far to achieve this
    Normal processing of code base in Jenkins, Overview page shows a warning. Log file contains stack-trace for failure:
2022.07.12 08:39:43 INFO  ce[AYHxkGIhMeSggZqRht3T][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Webhooks | globalWebhooks=0 | projectWebhooks=0 | status=SUCCESS | time=2ms
2022.07.12 08:39:43 INFO  ce[AYHxkGIhMeSggZqRht3T][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Pull Request decoration | status=SUCCESS | time=0ms
2022.07.12 08:39:44 WARN  ce[AYHxkGIhMeSggZqRht3T][c.s.F.C.A.B] Failed to access GitHub, the repository or the Pull Request
2022.07.12 08:39:44 WARN  ce[AYHxkGIhMeSggZqRht3T][c.s.F.D.F.J] Branch decoration failed
java.lang.IllegalStateException: Failed to report status to Devops platform: couldn't get the branch details
	at com.sonarsource.F.D.F.J.B(Unknown Source)
	at com.sonarsource.F.D.F.J.D(Unknown Source)
	at java.base/java.util.Optional.orElseThrow(Optional.java:408)
	at com.sonarsource.F.D.F.J.C(Unknown Source)
	at com.sonarsource.F.D.F.J.A(Unknown Source)
	at com.sonarsource.F.D.F.L.A(Unknown Source)
	at com.sonarsource.F.D.k.A(Unknown Source)
	at org.sonar.ce.async.SynchronousAsyncExecution.addToQueue(SynchronousAsyncExecution.java:27)
	at com.sonarsource.F.D.k.A(Unknown Source)
	at java.base/java.util.Optional.ifPresent(Optional.java:183)
	at com.sonarsource.F.D.k.finished(Unknown Source)
	at org.sonar.ce.task.projectanalysis.api.posttask.PostProjectAnalysisTasksExecutor.executeTask(PostProjectAnalysisTasksExecutor.java:102)
	at org.sonar.ce.task.projectanalysis.api.posttask.PostProjectAnalysisTasksExecutor.finished(PostProjectAnalysisTasksExecutor.java:93)
	at org.sonar.ce.task.step.ComputationStepExecutor.executeListener(ComputationStepExecutor.java:90)
	at org.sonar.ce.task.step.ComputationStepExecutor.execute(ComputationStepExecutor.java:62)
	at org.sonar.ce.task.projectanalysis.taskprocessor.ReportTaskProcessor.process(ReportTaskProcessor.java:75)
	at org.sonar.ce.taskprocessor.CeWorkerImpl$ExecuteTask.executeTask(CeWorkerImpl.java:212)
	at org.sonar.ce.taskprocessor.CeWorkerImpl$ExecuteTask.run(CeWorkerImpl.java:194)
	at org.sonar.ce.taskprocessor.CeWorkerImpl.findAndProcessTask(CeWorkerImpl.java:160)
	at org.sonar.ce.taskprocessor.CeWorkerImpl$TrackRunningState.get(CeWorkerImpl.java:135)
	at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:87)
	at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:53)
	at com.google.common.util.concurrent.TrustedListenableFutureTask$TrustedFutureInterruptibleTask.runInterruptibly(TrustedListenableFutureTask.java:131)
	at com.google.common.util.concurrent.InterruptibleTask.run(InterruptibleTask.java:74)
	at com.google.common.util.concurrent.TrustedListenableFutureTask.run(TrustedListenableFutureTask.java:82)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)
2022.07.12 08:39:44 INFO  ce[AYHxkGIhMeSggZqRht3T][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Report branch Quality Gate status to devops platforms | status=SUCCESS | time=1014ms
2022.07.12 08:39:44 INFO  ce[AYHxkGIhMeSggZqRht3T][o.s.c.t.CeWorkerImpl] Executed task | project=com.XXX.vod.catalog:pubmind-core | type=REPORT | branch=master | branchType=BRANCH | id=AYHxkGIhMeSggZqRht3T | submitter=sonar | status=SUCCESS | time=4426ms

Hi,

Could you go to the project’s Background Tasks page (under Project Settings) and use the cog menu on the relevant task to look at the scanner context? I’m interested in the ‘Project scanner properties’ section to know whether branch/PR parameters were passed to the analysis.

 
Ann