com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was STRING at line 1 column 5

Stack Overflow | Anderson Muniz | 6 months ago
tip
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    Expected BEGIN_ARRAY but was STRING at line 1 column 5

    Stack Overflow | 6 months ago | Anderson Muniz
    com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was STRING at line 1 column 5
  2. 0

    Editing Config

    GitHub | 6 years ago | lmk-chris
    com.google.gson.JsonSyntaxException: com.google.gson.stream.MalformedJsonException: invalid number or unquoted string near ?{ "colorMember": "G
  3. 0

    Outputting parsed JSON results from Google Custom Search in Java

    Stack Overflow | 3 years ago | gwar666
    com.google.gson.JsonSyntaxException: java.io.EOFException: End of input at line 1 column 2
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Retrofit - removing some invalid characters from response body before parsing it as json

    Stack Overflow | 2 years ago | pomber
    retrofit.RetrofitError: com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_OBJECT but was STRING at line 1 column 1
  6. 0

    Reading a JSON reply from WeatherUnderground

    Stack Overflow | 4 years ago | Little Child
    com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected a string but was BEGIN_OBJECT at line 1 column 2

  1. Nikolay Rybak 9 times, last 5 days ago
  2. justCodeit 11 times, last 3 weeks ago
  3. filpgame 4 times, last 4 weeks ago
  4. Emrah Küçük 9 times, last 3 months ago
  5. linxiaolong 4 times, last 3 months ago
19 more registered users
53 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.IllegalStateException

    Expected BEGIN_ARRAY but was STRING at line 1 column 5

    at com.google.gson.stream.JsonReader.expect()
  2. Gson
    Gson.fromJson
    1. com.google.gson.stream.JsonReader.expect(JsonReader.java:339)
    2. com.google.gson.stream.JsonReader.beginArray(JsonReader.java:306)
    3. com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:79)
    4. com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:60)
    5. com.google.gson.Gson.fromJson(Gson.java:795)
    6. com.google.gson.Gson.fromJson(Gson.java:761)
    7. com.google.gson.Gson.fromJson(Gson.java:710)
    7 frames
  3. ViaCEP_WebService
    HttpExemplo2.main
    1. ViaCEP_WebService.HttpExemplo2.main(HttpExemplo2.java:61)
    1 frame