google-developer-training / basic-android-kotlin-compose-training-mars-photos

Solution code for Android Basics in Kotlin course
https://developer.android.com/courses/android-basics-kotlin/course?gclid=CjwKCAjw4c-ZBhAEEiwAZ105RTyT-iaLHzrhMBUXdMhO230ZDwOwxxI2x4RgK8DwBxK8t1h0wmU_QxoCi4YQAvD_BwE
Apache License 2.0
72 stars 66 forks source link

Project: Create a Bookshelf App #125

Closed alghe-global closed 7 months ago

alghe-global commented 7 months ago

URL of codelab:

Specify the language of the codelab if it is not English:

In which task and step of the codelab can this issue be found?

Describe the problem

FATAL EXCEPTION: main
                                                                                                    Process: com.example.bookshelf, PID: 7621
                                                                                                    kotlinx.serialization.json.internal.JsonDecodingException: Expected start of the array '[', but had 'EOF' instead at path: $
                                                                                                    JSON input: .....",
                                                                                                            "quoteSharingAllowed": false
                                                                                                          }
                                                                                                        }
                                                                                                      ]
                                                                                                    }

                                                                                                        at kotlinx.serialization.json.internal.JsonExceptionsKt.JsonDecodingException(JsonExceptions.kt:24)
                                                                                                        at kotlinx.serialization.json.internal.JsonExceptionsKt.JsonDecodingException(JsonExceptions.kt:32)
                                                                                                        at kotlinx.serialization.json.internal.AbstractJsonLexer.fail(AbstractJsonLexer.kt:584)
                                                                                                        at kotlinx.serialization.json.internal.AbstractJsonLexer.fail$default(AbstractJsonLexer.kt:582)
                                                                                                        at kotlinx.serialization.json.internal.AbstractJsonLexer.fail$kotlinx_serialization_json(AbstractJsonLexer.kt:223)
                                                                                                        at kotlinx.serialization.json.internal.AbstractJsonLexer.unexpectedToken(AbstractJsonLexer.kt:206)
                                                                                                        at kotlinx.serialization.json.internal.StringJsonLexer.consumeNextToken(StringJsonLexer.kt:74)
                                                                                                        at kotlinx.serialization.json.internal.StreamingJsonDecoder.beginStructure(StreamingJsonDecoder.kt:100)
                                                                                                        at kotlinx.serialization.internal.AbstractCollectionSerializer.merge(CollectionSerializers.kt:29)
                                                                                                        at kotlinx.serialization.internal.AbstractCollectionSerializer.deserialize(CollectionSerializers.kt:43)
                                                                                                        at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeSerializableValue(StreamingJsonDecoder.kt:70)
                                                                                                        at kotlinx.serialization.json.Json.decodeFromString(Json.kt:107)
                                                                                                        at com.jakewharton.retrofit2.converter.kotlinx.serialization.Serializer$FromString.fromResponseBody(Serializer.kt:26)
                                                                                                        at com.jakewharton.retrofit2.converter.kotlinx.serialization.DeserializationStrategyConverter.convert(DeserializationStrategyConverter.kt:11)
                                                                                                        at com.jakewharton.retrofit2.converter.kotlinx.serialization.DeserializationStrategyConverter.convert(DeserializationStrategyConverter.kt:7)
                                                                                                        at retrofit2.OkHttpCall.parseResponse(OkHttpCall.java:243)
                                                                                                        at retrofit2.OkHttpCall$1.onResponse(OkHttpCall.java:153)
                                                                                                        at okhttp3.internal.connection.RealCall$AsyncCall.run(RealCall.kt:519)
                                                                                                        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
                                                                                                        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
                                                                                                        at java.lang.Thread.run(Thread.java:923)
                                                                                                        Suppressed: kotlinx.coroutines.internal.DiagnosticCoroutineContextException: [StandaloneCoroutine{Cancelling}@9cbfad6, Dispatchers.Main.immediate]

project is unsuitable

Steps to reproduce?

  1. Go to...
  2. Click on...
  3. See error...

Versions Android Studio version: API version of the emulator:

Additional information Include screenshots if they would be useful in clarifying the problem.

alghe-global commented 7 months ago

this was a bug in my app, closing

alghe-global commented 7 months ago

closing as not planned