Can SQLITE_INTERNAL be a transient error ?
SQLite doc describes SQLITE_INTERNAL as:
SQLITE_INTERNAL : The SQLITE_INTERNAL result code indicates an internal malfunction. In a working version of SQLite, an application should never see this result code. If application does encounter this result code, it shows that there is a bug in the database engine. SQLite does not currently generate this result code. However, application-defined SQL functions or virtual tables, or VFSes, or other extensions might cause this result code to be returned.
We need to be sure that SQLITE_INTERNAL is not a transient error but fatal error and user would continue to face issues accessing the sqlite database unless we recreate a new database.
Is there any way, we can confirm this ?
Given that the scope of
SQLITE_INTERNAL is so ill-defined, I don't see how blanket conclusions like "it's transient, retry", or "the DB's b0rked, time to recreate" can be made.
The only reasonable step to take is in fact "we need to investigate further, and we can't be sure the data's intact".