Gradle SonarCloud Integration

HI Need Help
GitHub
Github Actions

Our Setting:

plugins {
  id "org.sonarqube" version "2.8"
}

sonarqube {
  properties {
    property "sonar.projectKey", "<app>"
    property "sonar.organization", "<organization>"
    property "sonar.host.url", "https://sonarcloud.io"
  }
}

We already try using version 3.3
run by ./gradle build sonarqube --info

  • What went wrong:
:app:jacocoDevDebug (Thread[Execution worker for ':',5,main]) completed. Took 7.528 secs.

check_suite_focus=true#step:6:57175)AAPT2 aapt2-7.0.2-7396180-linux Daemon #0: shutdown

check_suite_focus=true#step:6:57176)

check_suite_focus=true#step:6:57177)Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
check_suite_focus=true#step:6:57178)Use '--warning-mode all' to show the individual deprecation warnings.

check_suite_focus=true#step:6:57179)See https://docs.gradle.org/7.0.2/userguide/command_line_interface.html#sec:command_line_warnings

check_suite_focus=true#step:6:57180)149 actionable tasks: 149 executed

check_suite_focus=true#step:6:57181)Watching 2955 directories to track changes

check_suite_focus=true#step:6:57182)Error: Process completed with exit code 1.

Hi @anjardanis

Error is not clear here. Can you provide a deeper log file please ?

Thanks.

Hi Mickael, Sorry for the late reply.

Ill try debug more and i know the issue but still dont know how to solve it

ask :app:processDevDebugAndroidTestManifest FAILED

See http://g.co/androidstudio/manifest-merger for more information about the manifest merger.

	android:exported needs to be explicitly specified for <activity>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details.
/home/runner/work/retailer-app/retailer-app/app/build/intermediates/tmp/manifest/androidTest/dev/debug/tempFile1ProcessTestManifest10979670820675286618.xml Error:
	android:exported needs to be explicitly specified for <activity>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details.
/home/runner/work/retailer-app/retailer-app/app/build/intermediates/tmp/manifest/androidTest/dev/debug/tempFile1ProcessTestManifest10979670820675286618.xml Error:
	android:exported needs to be explicitly specified for <activity>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details.

I got this error now, i want to exclude this

already do in sonarcloud UI and exclude in build.gradle like this

    property "sonar.exclusions", '**/*Test*/**,' +
            '*.json,' +
            '**/androidTest/**,' +
            '**/dev/**,' +
            '**/prod/**,' +
            '**/stg/**,' +
            '**/.gradle/**,' +
            '**/R.class'
    }
}

is there any i am wrong how to exclude this Thank you and sorry for really late reply