flagship-io / flagship-android

Flagship Android library for implementing campaigns in your native Android app.
Apache License 2.0
7 stars 2 forks source link

android.database.sqlite.SQLiteCantOpenDatabaseException #13

Open RobertKDroid opened 2 weeks ago

RobertKDroid commented 2 weeks ago

I have encountered a crash opening SQLITE db most probably caused by your sdk

Were using 3.0.4 SDK version and we do not use any DB or Workmanagers internally and my only trace of caused crash is

Caused by android.database.sqlite.SQLiteCantOpenDatabaseException Cannot open database '/data/user/0/APP.ID/no_backup/androidx.work.workdb' with flags 0x30000000: File /data/user/0/APP.ID/no_backup/androidx.work.workdb doesn't exist and CREATE_IF_NECESSARY is set, check directory permissions

Fatal Exception: java.lang.IllegalStateException The file system on the device is in a bad state. WorkManager cannot access the app's internal data store.

com.abtasty.flagship.utils.FlagshipContext.<clinit> (SourceFile:197) com.abtasty.flagship.main.Flagship.start (Flagship.java:4)

So far we have received one crash on Moto G 5G - 2023 Device with Android 13.

Please investigate if this is related to your's SDK

All the best

raf-abtasty commented 1 week ago

Hi @RobertKDroid, thx for your report.

We do not implement Workmanagers either and none of our dependencies seems to use it. Our SDK simply uses Room Database which relies on SQLiteDatabase, the default name would be like flagship-$envId-cache.db.

Do you have on your side one dependency that would use androidx.work:work-runtime ?

Regards

RobertKDroid commented 1 week ago

Hey, sadly no we do not use any kind of dependency like this. Stack trace related to flagship is only valid thing that i could catch up with

raf-abtasty commented 1 week ago

So far i tested without having any issue:

I am afraid to not being able to investigate more at this point without having more info that could help me to reproduce.

Dont hesitate to post more insights if you have any in the future.

Regards

RobertKDroid commented 1 week ago

Alright, thanks for heads up. So far we had one crash so im going to observe if this will occur again and ill post my findings

All the best