chRyNaN / serialization-parcelable

Android Parcelable support for the Kotlinx Serialization library.
Apache License 2.0
70 stars 3 forks source link

Android artifacts for 0.8.0 weren't published #8

Closed tadfisher closed 7 months ago

tadfisher commented 7 months ago

Looking at the Maven repository index, the following artifacts weren't published for version 0.8.0:

The Gradle module metadata is missing the android*Elements-published variants, so upgrading to 0.8.0 results in Gradle selecting the JVM variant for Android builds, which is definitely broken.

chRyNaN commented 7 months ago

Good catch, I think I know what the issue is. Will try and get an update out today. https://github.com/chRyNaN/serialization-parcelable/blob/develop/parcelable-core/build.gradle.kts#L20

chRyNaN commented 7 months ago

@tadfisher Could you try again? It looks like the android artifacts are now available. This was the issue:

// Before:
androidTarget()

// After:
androidTarget {
        publishAllLibraryVariants()
}
chRyNaN commented 7 months ago

BTW JVM should not be broken, if it is please file an issue. But JVM doesn't have the Android components or functionality (Intent, Bundle, etc).

tadfisher commented 7 months ago

But JVM doesn't have the Android components or functionality (Intent, Bundle, etc).

Right, so any Android source set depending on parcelable-core (expecting the Android variant) that uses the Android-specific APIs (encodeToBundle, etc) will fail to compile. I don't actually know if the JVM variant works on Android, to be clear.

Thank you for addressing this!