Eclipse debugging has dialog box: Exception processing async thread queue java.lang.NullPointerException
I am facing a problem while debugging in Eclipse 3.4.2. I keep getting pop-up Exception processing async thread queue java.lang.NullPointerExce开发者_JAVA百科ption
Does anyone know what the exact problem is?
Thanks
The problem was with the expressions watching while debugging. If those old expressions are not removed, it just keeps evaluating them and since they don't exist for current program, they keep throwing null pointer exception.
This is a known bug that the eclipse group is actively working on correcting. It is related to evaluating static variables in the debugger. Often show up when watching String[] variables. Prior comments about removing watched variables are partially correct, but only if they are static
Keep watching the eclipse release notes for a bug fix
I have the same problem, I found the relevant bug report: https://bugs.eclipse.org/bugs/show_bug.cgi?id=277574
I am using Eclipse 3.6.1, and the bug report says it is fixed in 3.6.1, however I still see it when I put a breakpoint in a Handler()
Exception processing async thread queue Exception processing async thread queue java.lang.UnsupportedOperationException
EDIT: I am able to see the value stored in the array of strings by adding the expression to the expression list. I only get the Eclipse exception when I put my mouse pointer over the array to inspect it. So I can debug, but I just have to remember to clear the expression list when I am done with it.
Eclipse Standard/SDK
Version: Kepler Service Release 1 Build id: 20130919-0819
I have a similar problem ... in the absence of a fix, I found a temporary workaround.
// This will cause the error as decribed in my code ...
public static void main(String[] args)
{
public static HashMap<String, String> students = new HashMap<String, String>();
...
}
if I sperate the declaration and initialisation ... I can get the debugger to behave as expected. Dont know why this works ... but appears to work for me ... Hope this helps someone.
public static HashMap<String, String> students ;
public static void main(String[] args)
{
students = new HashMap<String, String>();
...
}
I had the similar issue with processing async thread in debugging mode but with com.sun.jdi.ObjectCollectedException
Exception processing async thread queue
com.sun.jdi.ObjectCollectedException
no cleaning expression list, or anything else helps. But i noticed that my phone is working under ART
runtime environment and when am I switched back to Dalvik
async thread error is dissapeared.
精彩评论