error-prone: Infinite compilation on JDK11

When upgrading to JDK 11.01, the compilation never finishes but has high CPU activity. When removing ErrorProne, the compilation completes without a problem. I am unsure how to debug, e.g. to see what the javac process is doing, to provide more details.

Environment:

  • JDK 11.01 (upgrading from 10+46)
  • Mac OS X Mojave
  • Gradle 5.0
  • ErrorProne:
    • core: 2.3.2
    • javac: 9+181-r4173-1
    • plugin: 0.6
  • Annotation Processors:
    • autoFactory: 1.0-beta6
    • autoValue: 1.6.3
    • autoValueBuilder: 2.9.1

Of course if I disable the annotation processors then it fails due to the missing generated classes, but does terminate. Removing autoFactory leads to the hang, while autoValue is used too frequently to get a hang prior. So there is a chance that it is related to annotation processing (such as due to Gradle’s incremental support), but could be something else.

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 21 (4 by maintainers)

Most upvoted comments

Java 12 worked! 😅

Okay, I’ll try JDK 12 since that’s faster than making a custom build of the plugin.

P.S. Thanks for the help so far @Stephan202 & @cushon

No luck with disabling all checks. I also tried updating to 2.3.3-SNAPSHOT which also hangs.

at com.sun.tools.javac.code.DeferredCompletionFailureHandler$1.uninstall(jdk.compiler@11.0.1/DeferredCompletionFailureHandler.java:82)

Maybe this is JDK-8209055?

Are you using -XDcompilePolicy=simple? If so, does removing that flag make a difference?