java.lang.RuntimeException

An error occurred while executing doInBackground()

Samebug tips2

This means you had a syntax problem in your serialization/deserialization, check the Gson javadoc to check the right syntax: https://goo.gl/g7LnZb

This seems to be a bug in the-blue-alliance, fixed in version 4.2.3 (link for github in case you want the changelog: https://goo.gl/NQAKUf ). If you're not using it, it might be that you're parsing xml as json.

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web18669

  • via Appcelerator JIRA by Lokesh Choudhary, 7 months ago
    An error occurred while executing doInBackground()
  • via GitHub by billmeek
    , 5 months ago
    An error occurred while executing doInBackground()
  • via GitHub by lanceschi
    , 1 year ago
    An error occurred while executing doInBackground()
  • Stack trace

    • java.lang.RuntimeException: An error occurred while executing doInBackground() at android.support.v4.content.ModernAsyncTask$3.done(ModernAsyncTask.java:142) at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:355) at java.util.concurrent.FutureTask.setException(FutureTask.java:222) at java.util.concurrent.FutureTask.run(FutureTask.java:242) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) at java.lang.Thread.run(Thread.java:841) Caused by: com.google.gson.JsonSyntaxException: com.google.gson.stream.MalformedJsonException: Unterminated object at line 2 column 906 path $.scans[13].ssid at com.google.gson.Gson.fromJson(Gson.java:829) at com.google.gson.Gson.fromJson(Gson.java:779) at com.google.gson.Gson.fromJson(Gson.java:728) at com.google.gson.Gson.fromJson(Gson.java:700) at io.particle.android.sdk.devicesetup.commands.CommandClient.readResponse(CommandClient.java:129) at io.particle.android.sdk.devicesetup.commands.CommandClient.sendAndMaybeReceive(CommandClient.java:83) at io.particle.android.sdk.devicesetup.commands.CommandClient.sendCommandAndReturnResponse(CommandClient.java:57) at io.particle.android.sdk.devicesetup.loaders.ScanApCommandLoader.loadInBackground(ScanApCommandLoader.java:65) at io.particle.android.sdk.devicesetup.loaders.ScanApCommandLoader.loadInBackground(ScanApCommandLoader.java:26) at android.support.v4.content.AsyncTaskLoader.onLoadInBackground(AsyncTaskLoader.java:296) at android.support.v4.content.AsyncTaskLoader$LoadTask.doInBackground(AsyncTaskLoader.java:54) at android.support.v4.content.AsyncTaskLoader$LoadTask.doInBackground(AsyncTaskLoader.java:42) at android.support.v4.content.ModernAsyncTask$2.call(ModernAsyncTask.java:128) at java.util.concurrent.FutureTask.run(FutureTask.java:237) ... 3 more Caused by: com.google.gson.stream.MalformedJsonException: Unterminated object at line 2 column 906 path $.scans[13].ssid at com.google.gson.stream.JsonReader.syntaxError(JsonReader.java:1573) at com.google.gson.stream.JsonReader.doPeek(JsonReader.java:495) at com.google.gson.stream.JsonReader.hasNext(JsonReader.java:418) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:211) at com.google.gson.internal.bind.TypeAdapterRuntimeTypeWrapper.read(TypeAdapterRuntimeTypeWrapper.java:40) at com.google.gson.internal.bind.ArrayTypeAdapter.read(ArrayTypeAdapter.java:72) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.read(ReflectiveTypeAdapterFactory.java:117) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:217) at com.google.gson.Gson.fromJson(Gson.java:814) ... 16 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    9 times, 2 weeks ago
    Once, 1 month ago
    Unknown user
    Once, 11 months ago
    Unknown user
    2 times, 11 months ago
    Unknown user
    Once, 1 year ago
    30 more bugmates