Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Annotation processors must be explicitly declared now

Tags:

java

android

Error:Execution failed for task ':laMusique2May2016:javaPreCompileRelease'. > Annotation processors must be explicitly declared now.  The following dependencies on the compile classpath are found to contain annotation processor.  Please add them to the annotationProcessor configuration.     - auto-value-1.1.jar (com.google.auto.value:auto-value:1.1)   Alternatively, set android.defaultConfig.javaCompileOptions.annotationProcessorOptions.includeCompileClasspath = true to continue with previous behavior.  Note that this option is deprecated and will be removed in the future.   See https://developer.android.com/r/tools/annotation-processor-error-message.html for more details. 

I am seeing this issue, but the problem is auto-value-1.1.jar is not in my gradle files

like image 749
Ankit Srivastava Avatar asked Oct 26 '17 20:10

Ankit Srivastava


People also ask

How do I enable annotations on my processor?

Press Ctrl+Alt+S to open the IDE settings and select Build, Execution, Deployment | Compiler | Annotation Processors.

How do annotation processors work?

An annotation processor processes these annotations at compile time or runtime to provide functionality such as code generation, error checking, etc. The java. lang package provides some core annotations and also gives us the capability to create our custom annotations that can be processed with annotation processors.

How do I reopen my spring boot application?

Another way to restart our application is to use the built-in RestartEndpoint from Spring Boot Actuator. In the above code, we are using the RestartEndpoint bean to restart our application. This is a nice way of restarting because we only have to call one method that does all the work.


1 Answers

Even i had the same problem and finally i solved my problem by adding this to app level gradle file

android{ ....     defaultConfig{ ....     javaCompileOptions {         annotationProcessorOptions {             includeCompileClasspath true         }     } } buildTypes { ... } 

hope its solved someone's problem

like image 168
krishnamurthy Avatar answered Sep 21 '22 07:09

krishnamurthy