
It's probably also worth noting that at some point in the distant future, we plan to move Dagger to KSP which should remove the need to rely on kapt. I wish there was a better answer, but that's all I have for now. Avoid using java 11 in this situation - it works with java 8.Avoid using kapt in this situation - it works with annotationProcessor.

However, note that this is really just a hack that relies on the fact that Dagger currently doesn't inspect the super types directly, but the underlying bug is still there and may cause issues later if Dagger starts relying on it.

Compiling java with dependencies code#
To make Maven compile your Java code with a newer version of the Java compiler, you need to specify the Java compiler explicitly in your project's POM file ( pom.xml ). Why that is still the default Java compiler version is a good question, since Java 5 was released in 2004.

If you run into any problems when using the features below, you can contact us by entering an issue.
Compiling java with dependencies how to#
Check for compilation errors or a circular dependency with generated code. Spark applications often depend on third-party Java or Scala libraries. The default Java compiler version used by Maven is Java 1.5. This document will give you an overview of how to manage your Java project in Visual Studio Code. C:\.\app\build\tmp\kapt3\stubs\.\MainApplication.java:60: error: was unable to process this class because not all of its dependencies could be resolved.
