Status Update
Comments
ey...@gmail.com <ey...@gmail.com> #2
Using AGP 7.2.1 + Kotlin 1.7.0 also results in the runtime exception.
ad...@google.com <ad...@google.com>
je...@google.com <je...@google.com>
ga...@google.com <ga...@google.com> #3
The issues is in the IDE as I don't see ./samples/simple-portal/build/
in the classpath, when launching the app.
ey...@gmail.com <ey...@gmail.com> #4
Right, and it might not be related to KMP. I just had this happen in a Kotlin jvm module.
ga...@google.com <ga...@google.com> #5
This is an issue with initialization of the compiler output path for a module. In Android Studio EE it is
// ~/.cache/Google/AndroidStudioPreview2022.1/external_build_system/portal.c0ad72a8/modules/portals.samples.simple-portal.jvmMain.xml
<output url="file://$MODULE_DIR$/../../../../samples/simple-portal/build/intermediates/javac/debug/classes" />
and in IJ 2022.2 Beta it is
// ~/.cache/JetBrains/IdeaIC2022.2/external_build_system/portal.c0ad72a8/modules/portals.samples.simple-portal.jvmMain.xml
<output url="file://$MODULE_DIR$/../../../../samples/simple-portal/build/classes/kotlin/jvm/main" />
The bug is in AS as we set incorrect compiler output path for jvmMain module within a Gradle project that has AGP appled. This needs to be fixed in AS.
ga...@google.com <ga...@google.com> #6
Thank you for reporting this issue and for the sample project! The issue is now fixed and it will be released in EE Canary 9.
Change id: Id27a9e3db64147eaa7d34853c98bdb831dc83f76
ey...@gmail.com <ey...@gmail.com> #7
Looks like this is still happening in EE Beta 5 (I don't remember if I saw it working since Canary 9 or not).
ey...@gmail.com <ey...@gmail.com> #8
And now it started working. Didn't change anything, so maybe a weird env issue.
Description
On EE Canary 2 I am able to run this JVM app that depends on a KMP library .
If I update EE to any higher canary build, or if I update Kotlin to 1.7.0 , the project runs, and fails with the exception below. Running
./gradlew :samples:simple-portal:desktop-app:run
works fine.