Status Update
Comments
da...@google.com <da...@google.com> #2
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
da...@google.com <da...@google.com> #3
ad...@ally.rapido.bike <ad...@ally.rapido.bike> #4
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically (
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
ap...@google.com <ap...@google.com> #5
Branch: androidx-main
commit cf121571aac008a756b64cda13f76ae4db3e85a6
Author: Daniel Santiago Rivera <danysantiago@google.com>
Date: Wed May 29 11:14:42 2024
Link to Android's atomic lib in bundled SQLite
Fix Bundled SQLite loading for devices with older ARM architecture by linking to Android's atomic library instead of relying on Clang's extension (c_atomic) or GCC's built-ins as used in sqlite3.c.
Also add support for passing linker args to androidx's native compilation infra.
See also discussion in
Bug: 341639198
Test: Locally tested via BundledSQLiteDriverTest in a Nexus 5 on API 23
Change-Id: Ia818b7c4f1a990a1b5e35f4c7a3c89694aee0503
M buildSrc/private/src/main/kotlin/androidx/build/clang/ClangSharedLibraryTask.kt
M buildSrc/private/src/main/kotlin/androidx/build/clang/KonanBuildService.kt
M buildSrc/private/src/main/kotlin/androidx/build/clang/MultiTargetNativeCompilation.kt
M buildSrc/private/src/main/kotlin/androidx/build/clang/NativeTargetCompilation.kt
M sqlite/sqlite-bundled/build.gradle
da...@google.com <da...@google.com>
bo...@gmail.com <bo...@gmail.com> #6
I'm using androidx.room:room-runtime-android:2.7.0-alpha01.
This is the log:
Fatal Exception: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.myproject-ssibkzVuLAo7tvV0puYoEg==/base.apk"],nativeLibraryDirectories=[/data/app/com.myproject-ssibkzVuLAo7tvV0puYoEg==/lib/x86, /system/lib, /vendor/lib]]] couldn't find "libsqliteJni.so"
at java.lang.Runtime.loadLibrary0(Runtime.java:1011)
at java.lang.System.loadLibrary(System.java:1657)
at androidx.sqlite.driver.bundled.NativeLibraryLoader.loadLibrary(NativeLibraryLoader.android.kt:1)
at androidx.sqlite.driver.bundled.BundledSQLiteDriver.<clinit>(BundledSQLiteDriver.jvmAndroid.kt:1)
Thank you!
da...@google.com <da...@google.com> #7
Can you try using androidx.room:room-runtime-android:2.7.0-alpha04
and confirm if the issue is still present?
bo...@gmail.com <bo...@gmail.com> #8
da...@google.com <da...@google.com> #9
Ideally you could use AndroidSQLiteDriver
but Room has a bug with the AndroidSQLiteDriver
that is fixed in version 2.7.0-alpha05 that will be released in July 10 so I recommend that if you do switch to using AndroidSQLiteDriver
wait for the alpha05 release.
ro...@gmail.com <ro...@gmail.com> #10
I just received two errors from Crashlytics using androidx.sqlite:sqlite-bundled version 2.5.0-alpha06 and BundledSQLiteDriver for both Android and iOS.
Fatal Exception: java.lang.UnsatisfiedLinkError
dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/app/com.example.app-ACdqnxIlCwzIlzMdaeegRw==/base.apk"],nativeLibraryDirectories=[/data/app/com.example.app-ACdqnxIlCwzIlzMdaeegRw==/lib/x86, /system/lib, /vendor/lib]]] couldn't find "libsqliteJni.so"
And the exception is in .setDriver(BundledSQLiteDriver())
Both crashes were from a Nexus 5X running Android 8.1.0
I would say it is the same exception as in
ev...@due.network <ev...@due.network> #11
f2...@gmail.com <f2...@gmail.com> #12
Same crash on Pixel 6 Pro(android12),Nexus 5X(android8.1) on androidx.sqlite:sqlite-bundled version 2.5.0-alpha11 with room version 2.7.0-alpha11.
ke...@level.co <ke...@level.co> #13
androidx.sqlite:sqlite-bundled version 2.5.0-alpha11 with room version 2.7.0-alpha11
da...@google.com <da...@google.com> #14
For those experiencing this issue, can you provide any more detail: stacktrace, bug report, trends (specific API versions, specific manufacturer)?
Usually with UnsatisfiedLinkError
there is more in the logs / error mentioning why the native library couldn't be used, specifically the missing symbol. I have so far validated we are
ki...@protonmail.com <ki...@protonmail.com> #15
Same crash on Pixel 6 pro
androidx-room = "2.7.0-alpha11"
androidx-sqlite = "2.5.0-alpha11"
Attached a stack trace
da...@nutrium.com <da...@nutrium.com> #16
Does anyone knows if it's safe to use AndroidSQLiteDriver for android as a backup plan?
We also released the iOS app some weeks ago and until know we didn't catch any issue related to this.
da...@google.com <da...@google.com> #17
For the stacktrace in jni/<abi>/libsqliteJni.so
da...@nutrium.com <da...@nutrium.com> #18
We have the structure like in the screenshoot
Description
I created an Android app using Room (Kotlin Multiplatform) and distributed it on the Play Store. Crashlytics reported that some Android devices were failing to instantiate the BundledSQLiteDriver.
Here is the stack trace.
I did not reproduce the above error on my Pixel 4a/Android 13.
Sample project to trigger the issue.
I created a sample project with a configuration similar to the production application where the error occurred.
Line where the error occurred.
Devices with error reported by Crashlytics