-
Notifications
You must be signed in to change notification settings - Fork 203
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
java.lang.NoClassDefFoundError: Failed resolution of: Lkotlinx/atomicfu/AtomicFU #503
Comments
Hello! First off just a warning store5 is not stable yet. You are free to play with it but we do not recommend prod usage yet. As for the error. Could you try adding this dependency to modules uses store https://search.maven.org/artifact/org.jetbrains.kotlinx/atomicfu/0.18.5/pom |
I have tried adding the AtomicFU dependency in the Android project and checked with Kotlin versions 1.7.20 (used in the AtomicFU) and 1.7.21, but still, the same crash occurred in the Android. |
hmm strange, I have. KMP project where I was able to successfully add Store5 and compile the android app. https://github.com/AndroidDev-social/DodoForMastodon/blob/main/data/repository/build.gradle.kts#L35 I'll try to make an android specific sample. If you have something you can push for me to see not working that would help as well. I probably won't be able to get to this until after the holidays. Thank you for the report |
Hey all
@digitalbuddha Will get up fix tn |
@sridharshanmugam - Still hitting this unfortunately. Seems to be known Atomic FU issue. See Kotlin/kotlinx-atomicfu#145. Will investigate https://github.com/touchlab/Stately as alternative. For now please add the dependency explicitly |
Updated README |
Thank you for the updated solution @matt-ramotar . I think you can mention adding the AtomicFU dependency using |
How to reproduce the issue @matt-ramotar ? I tried howl-so/xplat@4f7b3c4 , but no (store) issue. |
Hey! Sorry to be slow. After cloning the repo and checking out that commit, the app should crash at runtime |
Hmm, yes the app crashes but with a different exception (not inited lateinit). I worked around those issues so the app starts at least and request data. But no atomicFu exception . |
Just wanna note , we're using store4-kmp in our team published on private maven without any problems. I don't even provide atomicFu as "api" just as "implementation". The only difference i can spot so far is that i'm not using the atmicFu plugin as that's not needed if provided via "implementation" |
When migrating from Store4 to Store5, the below-mentioned crash happened in the Android platform.
In the latest Store5, since the Kotlin version 1.7.21 is used, I have updated the Compose Compiler Version to 1.4.0-alpha02. But in the AtomicFU, they have mentioned turning on IR transformation by setting the below-mentioned properties in the
gradle.properties
file for Kotlin version >= 1.7.20.But in the Store5
gradle.properties
file, it was configured as mentioned below for the AtomicFU version 0.18.5.I'm not sure whether this might be the reason for the above-mentioned crash in the Android platform.
The text was updated successfully, but these errors were encountered: