Sonarcloud analysis fails on PRs for C# project on GitHub

I have setup a GitHub action for my CI that, among other things, triggers a sonarcloud analysis. It works perfectly well, unless a PR is analyzed. In this latter case, the “Begin Analysis Step” fails with the following error:

The format of the analysis property sonar.login= is invalid

For the record:

Is there something specific to PRs to activate (either on GitHub or Sonarcloud side)? If not, should I deactivate analysis for PRs?

Thanks for your insight!

Hi @odalet

Seems like secrets are not yet supported on forks on GitHub. Please make sure that this one is declared on the account that forked the repo as well.

Mickaël

So if I understand correctly, I should provide the person who forked my repo with a token so that the build of their PR can authenticate with Sonarcloud… I think I’ll do this on a per-contributor basis and let the analysis fail for now…

Anyway, thanks, as always, for the prompt reply!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.