How to debug unexpected exceptions (source not found)

by Frank Weiss » Wed, 10 Feb 2010 10:38:49 GMT

Sponsored Links
 @Bob I don't think you really nailed the problem. I ran into what I think is
a similar issue. The stack trace showed the location of the throw deep in
the Android API, without a hint of a stack frame from my code. I suppose the
problem is because some of the Android code runs in different threads, so
that the exception was probably due to some data structure from my code that
the API later trips over in another thread.

I tried downloading the Android source code and adding it the the Android
project source code path. This solved the "no source found" error in the
Eclipse debugger, but unfortunately, the source code line where the
exception supposably was thrown didn't show any reasonably rational Android
code. I suppose the reason might have been that I pulled down the wrong
version of Android source.

In the end, my problems were due to not using the API correctly. In one case
it was trying to manipulate the UI from the AsyncTask.doInBackground method.
In another case it was because it was calling populate several times on a
Overlay object instead of just once after all the items had been added.

I'd still like to see an answer to the OP because it might be quite
educating to step through the Android source code. I usually figure out what
went wrong by looking at the the code that actually threw the exception and
seeing the data structure that caused it to barf.


Other Threads

1. Upload large files on the web server on android


I want to upload files on a web server in my android app.Currently i
am able to upload files around 5mb from the device but more than this
gives a outofmemory exception and also makes app very unstable.

i am looking for a method using which we can upload the data in the
app background plus of bigger size. Any tutorials/ code is highly

thanks in advance.


2. Gimana sih cara upgrade android OS di handset kita ?

Bisa tunggu resmi, bisa jalur ngga resmi.. Biasanya yg ngga resmi lebih
manteb, apalagi klo yg resmi uda kluar, jadi custom rom-nya bisa based on yg

Cyanogen itu hanyalah 1 dari sekian banyak rom cooker, tapi buatan cyanogen
biasanya sudah stabil.. :)


3. Failed to set pid xxx ioprio

4. OMX Codec Integration

5. Google listen menghilang dari market

6. KoinKuLator v0.1

7. flash audio problems