Git hub check tabs shows "waiting for checks information" and also conversation not showing comments

Must-share information (formatted with Markdown):

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension) --> Developer Edition Version 8.6 (build 39681) and GitHub Enterprise version --> GitHub Enterprise Server 2.20.9
  • what are you trying to achieve --> Pull request decoration
  • what have you tried so far to achieve this --> followed the documentation and successfully created ALM integration but not showing comments and checks in Github.

Hi Abhijeet,

Assuming everything is configured properly, the way to troubleshoot PR decoration is:

  • Turn the log level to DEBUG (easiest via Administration / System menu)
  • Try the PR analysis again
  • Check the Compute Engine log (ce.log) for any signs of error

Hi Jeff
i don’t see any updates in logs apart from this line --> 2021.01.05 10:55:33 INFO ce[o.s.s.l.ServerLogging] Level of logs changed to DEBUG

Request you to please guide me here.

And did you re-attempt analysis? You must trigger a new analysis of the PR branch for anything to happen.

Let’s confirm a few things.

  • You’ve configured the ALM settings globally (under Administration / Configuration / ALM Integrations)
  • You’ve enabled the ALM configuration at the project level (under Project Settings / General Settings / Pull Request Decoration)
  • You’re including appropriate parameters to identify the Pull Request during analysis - please attach a full log of the analysis starting from the invocation of the sonar-scanner

Please find the requested details below.

  1. ALM Integration -->

  2. Project Settings / General Settings / Pull Request Decoration

  3. sonarqube_web.log (497.3 KB) sonarqube_es.log (126 Bytes) sonarqube_ce.log (66.7 KB)

Please verify this and let me know if you need anything apart from this.

Aha! I think I see the problem. In the project settings, the “Repository identifier” should be the org/repo name, not the full URL. So just aarewar/MyRepoOrigin in your case.

Try a fresh analysis after changing that and see if it fixes the issue.

@Jeff_Zapotoczny I tried as per above but still It didn’t worked and under checks tab in github show same (Waiting for checks information…) and no comment section too.

is there any way we can sync up on call? or what other details you need please let me know

This is strange, it seems SQ thinks the decoration succeeded:

2021.01.06 13:45:04 INFO ce[AXbWwwFii3t0TqtjDMEN][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Pull Request decoration | status=SUCCESS | time=0ms

As I requested yesterday:

please attach a full log of the analysis starting from the invocation of the sonar-scanner

I’d like to confirm that the analysis parameters line up with your expectations for the PR you’re trying to decorate.

Could you please specify the log file name?
SonarScannerLogs.txt (54.9 KB)
Please check the attached a logs if not works then please specify the log file name.

Thank you. I don’t see any evidence in those logs that you’ve actually directed the scanner to do a pull request analysis. The required parameters are missing.

1 Like

I have tried with the analysis parameter please check log file once
With analysis parameter.txt (34.0 KB)
Good new is now I can see the checks in GitHub now but with broken images.

Bingo! Glad that resolved it.

The broken images are almost certainly happening because your SonarQube server’s base URL isn’t set to something reachable by GitHub. You can configure it via Administration / General / Server base URL. The decorated markup added to GitHub includes references back to your SonarQube server to load the images.

@Jeff_Zapotoczny Firstly Thank you so much for your help in whole process much appreciated
Regarding broken image I have already configured
Administration / General / Server base URL

Let me know if I need to change anything.

Try removing the trailing slash from your URL; this has sometimes caused problems. And it will require a fresh PR decoration to test if this fixes things – the new URL value must be communicated fresh to GitHub.

If that somehow doesn’t resolve it, you’ll need to use your browser dev tools when loading the GitHub checks page to see what the true cause of the problem is. There could be other network-related issues at play.

Ok I will try with above solution.
One more thing wanted to check my sonar server is not accessible from other system.
I can only access it from localhost machine and not from any other machine.
How I can access it from other machine?

That’s more of a general networking question, not a SonarQube problem. It’s up to you to expose a port on your SQ server, possibly set up a reverse proxy, set up DNS if desired, etc. In cases where GitHub Enterprise (and not in the cloud) is used, we assume bi-directional communication between SQ and GitHub should be possible.

OK will figure it out on that.
Thanks again for all your help.

@Jeff_Zapotoczny Need one help
How do I enable this pull request decoration to all users?
Also guide me for required analysis parameter in pom.xml

Hi Abhijeet,

The approach we’d recommend to have analysis for all users is to perform the analysis centrally, preferably automated as part of a CI system like Jenkins. This way you don’t have to worry about every individual developer needing to run parameterized scans and getting it correct each time; analyzing the same project from multiple different workstations can also lead to issues if the project parameters aren’t set consistently.

I’m not clear what you’re asking regarding the pom.xml? You can add sonar analysis parameters directly in the pom.xml, however for dynamic parameters like PR I would instead recommend to pass them on the command line.

Do you have any sample example for analysis parameter?
How do I get pull request key at run time and without executing in command line?
Currently I am executing command line after pull request is generated.
But wanted to execute PR Decoration as soon as I create pull request without hitting command line?