NullPointerException with Sonar Gradle Plugin version 7.2.3.7755

We use the lates version of Sonar Gradle Plugin (org.sonarqube:7.2.3.7755) with the following sonar configuration in gradle.build.

sonar {
    properties {
        property 'sonar.host.url', "${sonarHostURL}"
        property 'sonar.projectKey', "${sonarProjectKey}"
        property 'sonar.token', "${System.env.SONAR_AUTH_TOKEN}"
        property 'sonar.projectDescription' , 'Sample'
    }
}

If I start the “sonar” Gradle task I get the following Exception:

Caused by: java.lang.NullPointerException: Cannot invoke "Object.equals(Object)" because the return value of "java.util.Map.get(Object)" is null
	at org.sonarqube.gradle.SonarPropertyComputer.overrideWithUserDefinedProperties(SonarPropertyComputer.java:311)
	at org.sonarqube.gradle.SonarPropertyComputer.computeDefaultProperties(SonarPropertyComputer.java:136)
	at org.sonarqube.gradle.SonarPropertyComputer.computeSonarProperties(SonarPropertyComputer.java:111)
	at org.sonarqube.gradle.SonarPropertyComputer.computeSonarProperties(SonarPropertyComputer.java:99)
	at org.sonarqube.gradle.SonarQubePlugin.lambda$configureTask$13(SonarQubePlugin.java:169)
	at org.gradle.api.internal.provider.DefaultProvider.calculateOwnValue(DefaultProvider.java:73)
	at org.gradle.api.internal.provider.AbstractMinimalProvider.calculateValue(AbstractMinimalProvider.java:115)
	at org.gradle.api.internal.provider.TransformBackedProvider.calculateOwnValue(TransformBackedProvider.java:81)
	at org.gradle.api.internal.provider.AbstractMinimalProvider.calculateValue(AbstractMinimalProvider.java:115)
	at org.gradle.api.internal.provider.MapCollectors$EntriesFromMapProvider.collectEntries(MapCollectors.java:203)
	at org.gradle.api.internal.provider.DefaultMapProperty$CollectingSupplier.lambda$calculateOwnValue$1(DefaultMapProperty.java:594)
	at org.gradle.api.internal.provider.AbstractCollectingSupplier.calculateValue(AbstractCollectingSupplier.java:87)
	at org.gradle.api.internal.provider.DefaultMapProperty$CollectingSupplier.calculateOwnValue(DefaultMapProperty.java:593)
	at org.gradle.api.internal.provider.AbstractMinimalProvider.calculateValue(AbstractMinimalProvider.java:115)

If I use previous version of Gradle plugin (org.sonartype:7.2.2.6593) everything works fine.

If I remove the property “sonar.projectDescription” from the Gradle configuration the exception does not occur even with the lates version of the Gradle plugin.

Hint for workaround of fix for problem would be appreciated.

Best regards
Ulrich

Hello @j2fxprgee,

Thank you for the feedback! This is a bug that was introduced in the latest version of the scanner. I have created a ticket for us to fix it.

Best regards,
Aurélien

Hello again,

We have released a new version of the scanner which should solve the issue reported in this thread.
We encourage you to try it out and share any feedback you might have about it with us.

Best regards,
Aurélien

Hey @j2fxprgee,
We did not hear back from you in this thread. Is it safe to assume that the latest release has been resolved for you?

Hello Dorian,

sorry for my late reply. Yes, the new release does solve the problem. Thanks.

Best regards
Ulrich