GitHub PR decoration- Not Working

  • which versions are you using (SonarQube 8.2 Enterprise Edition)
  • what are you trying to achieve
    Display PR Decoration after integrating Github App in the Sonarqube instance
  • what have you tried so far to achieve this
  • GitHub App created
    -ALM integrations completed by using AppID,, and base64 private key (all whitespaces removed).

The PR Analysis is displayed in Sonarqube project page, But the PR Decorations are not displayed in Github.

The error that pops up is -

PostProjectAnalysisTasksExecutor] Execution of task class com.sonarsource.C.D.a failed
java.lang.IllegalStateException: Failed to read Github Application private key

I setup a github app and sonar integration last night. Not sure if this helps, but I included the tags ------ BEGIN RSA PRIVATE KEY---- and the ending tag when pasting the key into the console. I did not receive an error.

@Benmatic I tried that too but when I try to include the begin and end tags, sonarqube doesn’t process the request. Any idea where it is going wrong ?

Not sure. Maybe an issue with your PEM key. Did you try to regenerate the key and paste again?

I tried almost everything. Strangely when I try to configure the same key (with end key and begin key tags) in another Enterprise edition instance of 8.3 version, it works fine. But doesn’t work for this specific instance even after upgrading from 8.2 to 8.3. Strange indeed !

Any leads will be helpful :slight_smile: @ganncamp @Kahn_Sylla

@sonarsourcers @Kahn_Sylla
Now I tried 2 scenarios in Two different instances of Enterprise 8.3 (build * 34182)

  • Enter RSA (.pem) key with BEGIN and END tags after removing all whitespaces
  • Enter RSA key without BEGIN and END tags

In both the cases, I get the same error -

2020.05.07 12:31:25 ERROR [o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Execution of task class com.sonarsource.C.D.c failed
java.lang.IllegalStateException: Failed to read Github Application private key
Caused by: Content can’t be read to a private key
… 38 common frames omitted
2020.05.07 12:31:25 INFO [o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Pull Request decoration | status=FAILED | time=9ms

P.S - And strangely, one instance took the RSA key with the begin/end tags and the other didnot. But since the error is same, I think the key format is not the issue here. So am I missing any configuration ?

Any Help will be appreciated .

Any help ??