feat: Add support for Android devices with 16 KB page size
Hello,
I'm working on a Capacitor project which uses capacitor-community-sqlite-6.0.2. Using an Android 15 emulator(API Level 35), which supports 16 KB page size(a new Android 15 feature described here), my app keeps crashing with a segmentation fault error.
After investigating the issue, I discovered that the culprit was
implementation 'net.zetetic:android-database-sqlcipher:4.5.3'
inside the android/build.gradle file.
Checking the android-database-sqlcipher repository, I discovered that it has been deprecated and its long-term relacement is here. I also discovered that version 4.6.1(as described in this issue already supports Android 15 devices with 16 KB page size.
Could you please change the following line inside the android/build.gradle file from
implementation 'net.zetetic:android-database-sqlcipher:4.5.3'
to
implementation "net.zetetic:sqlcipher-android:4.6.1@aar"
Thank you in advance!
Would you be willing to create a PR?
Hey, @robingenz, sure, I'll work on it and link it.
Thanks
Hi!
I submitted a PR to do this upgrade: https://github.com/capacitor-community/sqlite/pull/607
Thanks for working on this - solved the crash issue I was seeing!
I had this problem as well and used the fix by @dragermrb. Thank you!
Hi, I have the same problem in my capacitor app.
Is there any release planed or can I temporary fix it for myself until the fix is published?
I think you can install a PR on your project:
npm i capacitor-community/sqlite#pull/607
Note that the PR doesn't include the latest changes on capacitor-community/sqlite
Hi, i tryed but it doesn't work
[ERROR] TS2307: Cannot find module '@capacitor-community/sqlite' or its corresponding type declarations. [plugin angular-compiler]
You can download the plugin, build locally and install from the local copy
Donwload and extract: https://github.com/dragermrb/sqlite/archive/refs/heads/fix-16kb-pagesize.zip
cd ./fix-16kb-pagesize
npm i
npm run build
cd /path-to-your-app
npm i ../path-to/fix-16kb-pagesize
Here is a dev release for testing:
npm i @capacitor-community/[email protected]
If no bugs are reported in the next few days, I'll merge the PR from @dragermrb (#607).
@robingenz Just checking in - any updates on when this fix will be released?
Closed by #607