Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to fix "The following classes needed for analysis were missing"

i try to start a sonarqube analyze in my java project, but the task stops with an error.

Here the facts: gradle wrapper 4.10 sonarqube-gradle-plugin: 2.7.1 java 8

i have defined the plugin and execute "gradlew sonarqube". After that, all my unittest were executed ... but suddenly the process stopps with an error message :

The following classes needed for analysis were missing: apply test accept

18:20:37: Executing task 'sonarqube'...

:wrapper

BUILD SUCCESSFUL in 0s
1 actionable task: 1 executed
> Task :compileJava NO-SOURCE
> Task :processResources NO-SOURCE
> Task :classes UP-TO-DATE
> Task :compileTestJava NO-SOURCE
> Task :processTestResources NO-SOURCE
> Task :testClasses UP-TO-DATE
> Task :test NO-SOURCE
> Task :frontend:compileJava NO-SOURCE
> Task :frontend:processResources NO-SOURCE
> Task :frontend:classes UP-TO-DATE
> Task :frontend:compileTestJava NO-SOURCE
> Task :frontend:processTestResources NO-SOURCE
> Task :frontend:testClasses UP-TO-DATE
> Task :frontend:test NO-SOURCE
> Task :frontend:jar
> Task :application:compileJava
> Task :application:processResources
> Task :application:classes
> Task :application:compileTestJava
> Task :application:processTestResources NO-SOURCE
> Task :application:testClasses
> Task :application:test
The following classes needed for analysis were missing:
  apply
  test
  accept
> Task :sonarqube

Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/4.10/userguide/command_line_interface.html#sec:command_line_warnings

BUILD SUCCESSFUL in 25s
6 actionable tasks: 6 executed
18:21:03: Task execution finished 'sonarqube'.


if tried a downgrade of the sonarqube-plugin-version but it doesnt help.

How can i fix it?

best regards

Michael

like image 905
uweselbst Avatar asked May 23 '19 16:05

uweselbst


1 Answers

These warnings seems to be a bug regarding Java 8 lamda support in find-sec-bugs project:

  • https://github.com/spotbugs/sonar-findbugs/issues/123
  • https://github.com/find-sec-bugs/find-sec-bugs/issues/332

It seems that there is no fix for the bug, yet.

like image 169
Matthias B Avatar answered Nov 14 '22 13:11

Matthias B