Sonar cloud stopped to display new pull requests

Template for a good new topic, formatted with Markdown:

  • ALM used (GitHub, Bitbucket Cloud, Azure DevOps)
    Bitbucket
  • CI system used (Bitbucket Cloud, Azure DevOps, Travis CI, Circle CI
    Jenkins
  • Scanner command used when applicable (private details masked)
    ./gradlew sonar --no-configuration-cache
  • Languages of the repository
    Kotlin
  • Only if the SonarCloud project is public, the URL
    • And if you need help with pull request decoration, then the URL to the PR too
  • Error observed (wrap logs/code around with triple quotes ``` for proper formatting)
  • Steps to reproduce
    Updated sonar dependency to last version
    I copy-pasted gradle config from administration panel of SonarCloud
    Set SONAR_TOKEN as environment variable
    run ./gradlew sonar in my Jenkins CI or on local machine

There is no new reports in my cloud console

  • Potential workaround

Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

Hi,

Welcome to the community!

There’s not a lot to go on here. Can you share your analysis logs?

The analysis / scanner log is what’s output from the analysis command. Hopefully, the log you provide - redacted as necessary - will include that command as well.

This guide will help you find them.

 
Ann

sonar_check_logs.txt (1.9 MB)
I attached logs to this reply

Hi,

First, can you address this

11:42:46 Shallow clone detected, no blame information will be provided. You can convert to non-shallow with 'git fetch --unshallow'.

Whether or not blame data is available will have a direct impact on PR analysis.

Then if you’re still not seeing what you expect in SonarCloud, can you - as mentioned in the guide I linked - add --debug to your Gradle command and post the resulting log?

 
Ann

Hi
Our application is very big, so log huge too

hope it will help

Hi,

Thanks for the log.

It exposes your analysis token, so you’ll want to revoke that right away.

It also seems to end mid-stream…?

[2023-07-28T07:42:47.901Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-navigation-json attribute artifactType value {artifactType=android-navigation-json, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.901Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-public-res attribute artifactType value {artifactType=android-public-res, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.901Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-res attribute artifactType value {artifactType=android-res, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.901Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-symbol attribute artifactType value {artifactType=android-symbol, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.902Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-symbol-with-package-name attribute artifactType value {artifactType=android-symbol-with-package-name, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.902Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:avia:order:data:common:debugRuntimeElements' variant jar attribute artifactType value {artifactType=jar, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.libraryelements=jar, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.903Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.DefaultAttributeMatcher] Selected matches [14] from candidates [configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-aar-metadata, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-art-profile, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-assets, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-classes-directory-Aorg.gradle.libraryelements=classes, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-classes-jar, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-compiled-dependencies-resources, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-consumer-proguard-rules, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-java-res, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-jni, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-lint, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-lint-local-aar, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-lint-model-metadata, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-lint-variant-dependencies-model, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-lint-variant-dependencies-partial-results, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-manifest, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-navigation-json, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-public-res, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-res, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-symbol, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant android-symbol-with-package-name, configuration ':feature:avia:order:data:common:debugRuntimeElements' variant jar] for {artifactType=android-manifest, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm}
[2023-07-28T07:42:47.904Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:trains:order:data:api:debugRuntimeElements' variant android-aar-metadata attribute artifactType value {artifactType=android-aar-metadata, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-manifest
[2023-07-28T07:42:47.904Z] 2023-07-28T07:40:44.647+0000 [DEBUG] [org.gradle.internal.component.model.LoggingAttributeMatchingExplanationBuilder] Candidate configuration ':feature:trains:order:data:api:debugRuntimeElements' variant android-art-profile attribute artifactType value {artifactType=android-art-profile, com.android.build.api.attributes.AgpVersionAttr=8.0.2, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, org.gradle.category=library, org.gradle.jvm.environment=android, org.gradle.usage=java-runtime, org.jetbrains.kotlin.platform.type=androidJvm} doesn't requested value android-

I’m guessing something maxed out, size-wise.

It looks like you have a lot of modules in this project. Is it possible to limit the build to one or two that have changes and give me that log?

 
Ann

You’re right, we have 200+ modules
Can you tell me, how to limit build for some modules?
You mean running scan like
./gradlew app:moduleName sonar ?

Hi,

I was hoping you would know. :sweat_smile:

 
Ann

Hi,

BTW, I did notice this:

+ ./gradlew sonar -D sonar.pullrequest.branch=feature/ADR-11192_fix_sonarqube_reports -D sonar.pullrequest.key=6494 -D sonar.pullrequest.base=develop --debug

Those spaces between -D and the key/value pairs need to go away. It may actually be the root of this. (I spend so long slogging through your log that it kinda slipped my mind)

 
Ann

yes, our log is very fascinating
I will try to run scan with this fix
And about scan for only modules with changes, as I no there is no such functionality
I hope sonar will do it in newer versions, because every run takes a very long time

No, it didn’t helped
When I tryin navigate from bitbucket, I see this error:

The requested project does not exist, or you have not been granted access.

Make sure the project has been analyzed successfully, hasn’t been deleted, and that you are authenticated to SonarCloud with a user account with permission to view the project.

@ganncamp

We are seeing the same error as of July 28. Our CI completes sonar runner with success and gives us a link to SonarCloud, but that link gives the error. On the GitHub side we see that Sonar has tried to analyze but it was cancelled:

SonarCloud / SonarCloud Code Analysis
cancelled yesterday in 1m 25s

I suspect that a change happened in recent days on the SonarCloud side and that some projects PR analysis is now failing, giving the cancel status. This is happening to several of our private projects.

We have this error more than one month
With all our PRs and in branch analysis

I found reason of this issue
It’s very simple, but for me, this reason is not obvious and it was difficult to find

Impossible to process any new analysis. The plan for the organization ‘onetwotrip’ has expired.
Please contact the administrator of the organization to resolve this issue.

I found it Administratin → Background tasks, why there are no any warning or errors on main page?

Hi @sodul,

You’re seeing this?

Can you characterize these projects? Are they all

  • the same language
  • large / small / whatever
  • OP’s building with Gradle. Are you?
  • any other commonalities?

 
Ann

Hi @Vitaliy_Ermakov,

I’m glad you worked through this, and I’m sorry the problem was so hard to find. I’m going to raise this internally. And at the same time, I would have expected an email to be sent to your organization’s admins…?

@sodul, since Vitaliy has found his cause, can you please create a new thread with all your details?

 
Ann

And at the same time, I would have expected an email to be sent to your organization’s admins…?
My account has admin rights in this organisation unit, and I didn’t receive any emails
Maybe it was sent on service account, I don’t know
Please, do some warning on this page for this case

Another one thing, sorry that I asking you in this topic
As you see, for every PR we analysing whole project, even if changes in one file. Do you planning feature for Gradle, for “diff analyse”? Because sonar gradle task processing approximate 20 minutes, and we have more than 30 PR’s in one time

Hi,

That deserves a new thread.

 
Thx,
Ann

@ganncamp

It seems billing related as well. I’m an admin and can see the Billing page on SonarCloud. We have renewed our payment before the 28 but have not received the new license key yet.

I’m following up internally, and let’s continue conversation privately.

1 Like