Problem: Gradle Kotlin builds do not work:
:compileKotlin
Using kotlin incremental compilation
Caught an exception trying to connect to Kotlin Daemon
java.lang.ClassNotFoundException: com.sun.tools.javac.util.Context
...
Could not perform incremental compilation: Could not connect to Kotlin compile daemon
Could not connect to kotlin daemon. Using fallback strategy.
java.lang.ClassNotFoundException: com.sun.tools.javac.util.Context
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
Solution: terminate the Gradle daemon, e.g. use ./gradlew --stop. If the problem persists, you might want to disable Gradle daemons.