CoffeeJack / EECE496

funf framework data collect
0 stars 0 forks source link

bug stale data exception if the call log probe/sms probe is checked #8

Open thoriqsalafi opened 10 years ago

thoriqsalafi commented 10 years ago

Hi,

there is bug if the call log or sms probe is checked, it said that the cursor is closed

02-25 10:30:49.466: E/AndroidRuntime(10959): FATAL EXCEPTION: Thread-2758 02-25 10:30:49.466: E/AndroidRuntime(10959): android.database.StaleDataException: Attempted to access a cursor after it has been closed. 02-25 10:30:49.466: E/AndroidRuntime(10959): at android.database.BulkCursorToCursorAdaptor.throwIfCursorIsClosed(BulkCursorToCursorAdaptor.java:64) 02-25 10:30:49.466: E/AndroidRuntime(10959): at android.database.BulkCursorToCursorAdaptor.getCount(BulkCursorToCursorAdaptor.java:70) 02-25 10:30:49.466: E/AndroidRuntime(10959): at android.database.AbstractCursor.isLast(AbstractCursor.java:257) 02-25 10:30:49.466: E/AndroidRuntime(10959): at android.database.CursorWrapper.isLast(CursorWrapper.java:142) 02-25 10:30:49.466: E/AndroidRuntime(10959): at edu.mit.media.funf.probe.ContentProviderProbe$ContentProviderIterator.hasNext(ContentProviderProbe.java:213) 02-25 10:30:49.466: E/AndroidRuntime(10959): at edu.mit.media.funf.probe.ContentProviderProbe.sendProbeData(ContentProviderProbe.java:131) 02-25 10:30:49.466: E/AndroidRuntime(10959): at edu.mit.media.funf.probe.ContentProviderProbe$1.run(ContentProviderProbe.java:86) 02-25 10:30:49.466: E/AndroidRuntime(10959): at java.lang.Thread.run(Thread.java:841)

can you correct this error?

CoffeeJack commented 10 years ago

This seems like a framework error. Be sure to use the most up-to-date FunF framework.

thoriqsalafi commented 10 years ago

thank you for your answer!, oh I see, actually I use the same funf 0.3 as in your code. i believe that last time your code is working so mine should work too.

i tried to update to 0.3.1 but still get the same error

there is stable version funf0.4 now, but the framework is very difference. to use this library, I have to make the code from scratch too and I am not that familiar with this kind of code. do you have any suggestion to correct the error?

CoffeeJack commented 10 years ago

Make sure the relevant services are enabled in your manifest. Depending on the data you want to collect you must first grant privileges.