Closed DatL4g closed 1 year ago
That might be an issue with IDEA. You can try deleting the .idea
folder and reopening the project, and see if this helps. Also what Kotlin version you are using? Can you try Kotlin 1.7.21? Do you have a reproducer project?
I have just checked, it works just fine for me:
1.7.20
223-1.7.21-release-272-IJ8214.52
I tried deleting the .idea
folder but that didn't help.
I'm using Kotlin version 1.7.22
I don't really have a reproducer project, but this is the project I'm facing this issue. (compose branch) It's not that small so for explanation:
Example class having this issue dev.datlag.burningseries.ui.screen.home.HomeScreenComponent
Thanks! Looks like it was broken in #73. Parcelize
annotation was marked as @OptionalExpectation
and removed from all non-Android targets. Since you are using only android
and jvm
targets, it resolves to the jvm
artifact (not common) which doesn't have Parcelize
anymore. I will revert this particular change.
I think this happens because Kotlin commonizer doesn't support sharing android
and jvm
source sets yet. So it defaults to just jvm
.
Looks like we can't use @OptionalExpectation
at all, I will avoid it completely for now.
Cc: @sellmair
Version 0.7.1
is released and should fix this issue. Please allow ~2 hours for artifacts to fully propagate.
Works like a charm, btw I just check the artifact availability here https://repo1.maven.org/maven2/com/arkivanov/essenty/parcelable/
Yeah, it's often faster than 2 hours. But there are more target-specific artifacts, they are synchronized in batches, so some targets may be still missing. https://repo1.maven.org/maven2/com/arkivanov/essenty/
The issue can still be reproduced on latest version 1.1.0 for nested classes.
Can you share a reproducer?
Maybe later
The latest version (0.7.0) shows the Parcelize annotation red with this error message: "Unresolved reference: Parcelize" in IntelliJ Ultimate 2022.3.1
This is NOT urgent as the project builds fine, just a little annoying.
Version 0.6.0 doesn't have this problem.