InterruptedException when debugging Android app-ThrowExceptions

Exception or error:

When debugging in Android Studio, in certain scenarios the app crashes with following exception:

08-27 18:01:25.144  19241-24656/? E/AndroidRuntime﹕ FATAL EXCEPTION: pool-7-thread-1
Process:, PID: 19241
        at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.reportInterruptAfterWait(
        at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(
        at java.util.concurrent.LinkedBlockingQueue.take(
        at java.util.concurrent.ThreadPoolExecutor.getTask(
        at java.util.concurrent.ThreadPoolExecutor.runWorker(
        at java.util.concurrent.ThreadPoolExecutor$

This happens

  • only when debugging
  • only on certain devices (i.e. Moto G, Nexus 4)

It does not happen on Oneplus One or Xperia L for example.

I haven’t found any other information to help us identify the problem. Anybody else running into this issue?

How to solve:

Try Async Task or for your part of code.
looks Synchronizing problem.

public class Task extends AsyncTask<Void, Void, Void>
        protected void onPreExecute() {

        protected Void doInBackground(Void... paths) {
            //here your code (approx from line 400 to 850)
           return null;

        protected void onPostExecute(Void result) {

for call Task on button click or from any other method

new Task().execute();

Leave a Reply

Your email address will not be published. Required fields are marked *