braintree / braintree_android

Braintree SDK for Android
https://developer.paypal.com/braintree/docs/start/hello-client/android/v4
MIT License
407 stars 233 forks source link

Fatal Exception: android.database.sqlite.SQLiteDatabaseCorruptExceptionfile is encrypted or is not a database #204

Closed NKosyanchuk closed 6 years ago

NKosyanchuk commented 6 years ago

Issue description

We are getting a lot of crashes with the same crashlitics logs: `

Fatal Exception: android.database.sqlite.SQLiteDatabaseCorruptExceptionfile is encrypted or is not a database (code 26)

  | android.database.sqlite.SQLiteConnection.nativeExecuteForLong (SQLiteConnection.java)   | android.database.sqlite.SQLiteConnection.executeForLong (SQLiteConnection.java:598)   | android.database.sqlite.SQLiteSession.executeForLong (SQLiteSession.java:652)   | android.database.sqlite.SQLiteStatement.simpleQueryForLong (SQLiteStatement.java:107)   | android.database.DatabaseUtils.longForQuery (DatabaseUtils.java:845)   | android.database.DatabaseUtils.longForQuery (DatabaseUtils.java:833)   | android.database.sqlite.SQLiteDatabase.getVersion (SQLiteDatabase.java:866)   | android.database.sqlite.SQLiteOpenHelper.getDatabaseLocked (SQLiteOpenHelper.java:241)   | android.database.sqlite.SQLiteOpenHelper.getReadableDatabase (SQLiteOpenHelper.java:187)   | com.braintreepayments.api.internal.AnalyticsDatabase.getPendingRequests (AnalyticsDatabase.java:87)   | com.braintreepayments.api.internal.AnalyticsIntentService.onHandleIntent (AnalyticsIntentService.java:93)   | android.app.IntentService$ServiceHandler.handleMessage (IntentService.java:68)   | android.os.Handler.dispatchMessage (Handler.java:102)   | android.os.Looper.loop (Looper.java:154)   | android.os.HandlerThread.run (HandlerThread.java:61)

`

crookedneighbor commented 6 years ago

This should be fixed in v2.13.0

https://github.com/braintree/braintree_android/blob/master/CHANGELOG.md#2130