Saturday, October 3, 2015

Solving "Unfortunately the process com.android.phone has stopped" problem (on Android Emulator)

Not sure why, but, suddenly one of my Android Emulators started throwing out the "...com.android.phone has stopped..." message. Unfortunately, it continuously throws that popup over and over again...

While googling around for the solutions - it seemed like there is some problem with the sqlite database of one of the telephony applications.

Logcat shows something like:
E/AndroidRuntime( 1293): android.database.sqlite.SQLiteException: Can't upgrade read-only database from version 327686 to 393222: /data/data/com.android.providers.telephony/databases/telephony.db

To solve this some posts suggested clearing cache, unfortunately navigating to the menu was troublesome (and didn't really work for me), so I instead used:
$ adb shell
$ pm clear com.android.phone
$ rm /data/data/com.android.providers.telephony/databases/telephony.db
(I guess, pm clear com.android.providers.telephony should work as well instead of the last command) 


References:
http://www.redips.net/android/emulator-phone-stopped-unexpectedly/ 
http://stackoverflow.com/questions/16879346/the-process-com-android-phone-has-stopped-unexpectedly-please-try-again

No comments: