You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
2022-08-15 22:27:46.237 [DefaultDispatcher-worker-1] INFO ktor.application - Responding at http://0.0.0.0:9090
2022-08-15 22:27:48.945 [eventLoopGroupProxy-4-1] ERROR ktor.application - Unhandled: POST - /shoppingList
java.lang.VerifyError: class kotlinx.serialization.json.internal.StreamingJsonDecoder overrides final method kotlinx.serialization.encoding.AbstractDecoder.decodeSerializableElement(Lkotlinx/serialization/descriptors/SerialDescriptor;ILkotlinx/serialization/DeserializationStrategy;Ljava/lang/Object;)Ljava/lang/Object;
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1017)
at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:174)
at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:800)
at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:698)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:621)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:579)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
at kotlinx.serialization.json.Json.decodeFromString(Json.kt:99)
at io.ktor.serialization.kotlinx.KotlinxSerializationConverter.deserialize(KotlinxSerializationConverter.kt:55)
at io.ktor.server.plugins.contentnegotiation.RequestConverterKt$convertRequestBody$1$1.invokeSuspend(RequestConverter.kt:38)
at io.ktor.server.plugins.contentnegotiation.RequestConverterKt$convertRequestBody$1$1.invoke(RequestConverter.kt)
...
After spending a while looking through this error, it turns out that the fix is to revert this line in build.gradle.kts from this:
val serializationVersion = "1.3.3"
To this:
val serializationVersion = "1.3.2"
After doing this, the application works.
The text was updated successfully, but these errors were encountered:
I downloaded the latest version of this code and it fails when attempting the following as per the tutorial:
The error I receive is:
After spending a while looking through this error, it turns out that the fix is to revert this line in
build.gradle.kts
from this:To this:
After doing this, the application works.
The text was updated successfully, but these errors were encountered: