WebView causes SQLiteDiskIOException WebView causes SQLiteDiskIOException sqlite sqlite

WebView causes SQLiteDiskIOException


You may be able to utilize setUncaughtExceptionHandler() in order to catch the exception and gracefully handle it.


I too am struggling to find the exact source of these errors. I have found a thread on the Google Groups AdMob forum that suggests it might be related to the AdMod SDK. For me, these errors started showing up after I published my latest update, which among other changes included upgrading the AdMob SDK from v4.1.1 to v4.3.1. Are you using AdMob?

Seems that the AdMob SDK in some circumstances manipulates its WebViews off of the UI thread, which I guess could cause various problems, possibly i.e. concurrent SQLite access from different threads when managing the cache. Possibly related to SQLiteDiskIOException in Android. Might also be worthwhile checking that your own code does not manipulate WebViews off of the UI thread.


There is an issue reported in code.google site.

EDIT : If you are ready to disable the cache, the exception's frequency might decrease a bit.

try{  Method m = CacheManager.class.getDeclaredMethod("setCacheDisabled", boolean.class);  m.setAccessible(true);  m.invoke(null, true);}catch (Throwable e){  Log.i("myapp","Reflection failed", e);}