-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
usercache local storage was deleted and does not stick #750
Comments
Looking at the user's logs, this has been going on since June 6th. It might have even occured earlier, but previous logs were truncated.
Every single time, we say that we will copy the local to the native, but the copy never seems to "stick"
|
My first thought was that this may be an issue with accessing the database from javascript.
also fails
|
Further, the last trip recorded by the user is from
|
Have asked the user to uninstall + reinstall, but to send me the userCacheDB before doing so. |
Note also that the loggerDB was apparently not affected, so it is not true that iOS cleared out ALL the databases. |
the user sent the
So the database was in fact corrupted. |
Reasons why sqlite could be corrupted: I think we can rule out 4. Disk Drive and Flash Memory Failures since the related logger was not affected. But a lot of the others relate to various file system operations that we have no control over and are opaque on iOS
but not sure if the Similarly, 1.1. Continuing to use a file descriptor after it has been closed can interact with iOS background processes in unexpected ways. the SQLite page also links to a similar error that facebook found and fixed I hope it doesn't come to that level of debugging - we don't have a ton of people capable of adding hooks into native code libraries, and we have a lot of priorities to handle - but this is not going to be an easy fix for sure 😦 |
It also looks like this is not unheard-of
Some concrete fixes (https://sqlite.org/forum/forumpost/5a46109077):
|
Found a similar issue in the more standard SQLite plugin, fixed using the |
Worried about making a major change to storage at this point; tempted to just port over all their changes to my plugin instead. These appear to be:
Note also that we include the sqlite3 library directly
while they include the sqlite source directly, which allows them to control how it is compiled
which seems like a fairly major change to make outside of the migration cycle. |
wrt
None of the standard deletion commands work. We would have to copy over the blank database.
The more I think about this, the more I think it is likely that the error is due to a power loss before the data was saved, which can be fixed by That is also the final conclusion in the SQLite store issue (number 34)
which also indicates that the multithreading fix is not a real fix.
|
Reported by a user:
Note that, unlike e-mission/e-mission-phone@a09385b (part of e-mission/e-mission-phone#470), this time the local storage was not empty and the usercache was empty.
The text was updated successfully, but these errors were encountered: