Open breandan opened 2 years ago
Hi! Yes, upgrading JVM target is the expected step, because I've updated JVM target for the library.
The exception in test is odd, but I suppose that it's because of different versions of kotlin-compiler-embeddable on classpath:
1.8.xx
is from Jupyter API testkit, 1.7.10
is probably from your dependencies. They're conflicting and create this effect. I either can try to release the version which depends on 1.7.10
, or you may try to get rid of this dependency.
I think org.jetbrains.kotlin:kotlin-compiler-embeddable:1.7.10
is a transitive dependency from KSP which conflicts with the KSP library integration method. I found KSP is also inherited from some standard Kotlin dependencies, I found this dependency tree from ./gradlew dependencies
(IDK why org.jetbrains.kotlin:kotlin-scripting-compiler-embeddable:1.7.10
depends on the 1.6.0
branch of KSP...):
kotlinCompilerPluginClasspathJvmMain - Kotlin compiler plugins for compilation 'main' (target jvm (jvm))
+--- org.jetbrains.kotlin:kotlin-scripting-compiler-embeddable:1.7.10
| +--- org.jetbrains.kotlin:kotlin-scripting-compiler-impl-embeddable:1.7.10
| | +--- org.jetbrains.kotlin:kotlin-scripting-common:1.7.10
| | | \--- org.jetbrains.kotlin:kotlin-stdlib:1.7.10
| | | +--- org.jetbrains.kotlin:kotlin-stdlib-common:1.7.10
| | | \--- org.jetbrains:annotations:13.0
| | +--- org.jetbrains.kotlin:kotlin-scripting-jvm:1.7.10
| | | +--- org.jetbrains.kotlin:kotlin-script-runtime:1.7.10
| | | +--- org.jetbrains.kotlin:kotlin-stdlib:1.7.10 (*)
| | | \--- org.jetbrains.kotlin:kotlin-scripting-common:1.7.10 (*)
| | \--- org.jetbrains.kotlin:kotlin-stdlib:1.7.10 (*)
| \--- org.jetbrains.kotlin:kotlin-stdlib:1.7.10 (*)
\--- com.google.devtools.ksp:symbol-processing:1.6.0-1.0.2
+--- org.jetbrains.kotlin:kotlin-stdlib:1.6.0 -> 1.7.10 (*)
+--- org.jetbrains.kotlin:kotlin-compiler-embeddable:1.6.0
| +--- org.jetbrains.kotlin:kotlin-stdlib:1.6.0 -> 1.7.10 (*)
| +--- org.jetbrains.kotlin:kotlin-script-runtime:1.6.0 -> 1.7.10
| +--- org.jetbrains.kotlin:kotlin-reflect:1.6.0
| | \--- org.jetbrains.kotlin:kotlin-stdlib:1.6.0 -> 1.7.10 (*)
| +--- org.jetbrains.kotlin:kotlin-daemon-embeddable:1.6.0
| +--- org.jetbrains.intellij.deps:trove4j:1.0.20181211
| \--- net.java.dev.jna:jna:5.6.0
\--- com.google.devtools.ksp:symbol-processing-api:1.6.0-1.0.2
\--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.6.0
+--- org.jetbrains.kotlin:kotlin-stdlib:1.6.0 -> 1.7.10 (*)
\--- org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.6.0
\--- org.jetbrains.kotlin:kotlin-stdlib:1.6.0 -> 1.7.10 (*)
I released a version that depends only on stable Kotlin 1.7.10, but it didn't resolve the problem. Then, I commented the following line in your build script: https://github.com/breandan/galoisenne/blob/88bc47a098ac3731d6c4b7cc72714055a167180a/build.gradle.kts#L198
And test passed. Exception actually arises in this compiler testing plugin, in this line: https://github.com/tschuchortdev/kotlin-compile-testing/blob/e45b94f8be546da692ba9c21fc09218fcbc15cbe/core/src/main/kotlin/com/tschuchort/compiletesting/MainCommandLineProcessor.kt#L16
So maybe you should report this problem in https://github.com/tschuchortdev/kotlin-compile-testing/issues/new
Hi Illya, thank you very much for investigating. I tried updating to 0.11.0-136-1
and commenting out the kotlin-compile-testing
dependency as you suggested, however this produced a Gradle internal error and I was unable to trace it back to the mentioned dependency or get the tests to pass. Tangentially, I did report a previous issue (tschuchortdev/kotlin-compile-testing#300) with that very library, however I believe it is related to updating to JVM 11.
It's not an internal error, it's just a compilation error (see the last Caused by). If you haven't commented out the tests that use kotlin-compile-testing plugin, it's expected.
I filed another issue there: https://github.com/tschuchortdev/kotlin-compile-testing/issues/301
I recently tried updating from
0.11.0-125
to0.11.0-134
, however compilation failed after doing so with the following error:In order to resolve it, I added the following snippet to my
build.gradle.kts
file:This compiled, but subsequently produced the following error when running
./gradlew allTests
:After encountering this error, I decided to add the following line to the
build.gradle.kts
file:However I then encountered the following issue:
This resulted in the second error reappearing. Currently it is unclear how to proceed, any advice would be appreciated.