Fixed
Status Update
Comments
yb...@google.com <yb...@google.com>
da...@google.com <da...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-main
commit c73bd92631a2ff341f89001bc9143c7b998333e8
Author: Sanura N'Jaka <sanura@google.com>
Date: Thu Aug 18 18:03:13 2022
Add project dependency constraint between lifecycle-viewmodel and lifecycle-viewmodel-savedstate
Added bi-directional project version constraint between
lifecycle-viewmodel and lifecycle-viewmodel-savedstate.
If both artifacts are in the dependency tree, their
versions should match. This will now be enforced by gradle
automatically bumping up either version to meet constraint.
Test: N/A
Bug: 242871265
Change-Id: I3ab2abf9b6b1861038afc0e651da80e4ee75efb8
M lifecycle/lifecycle-viewmodel-savedstate/build.gradle
https://android-review.googlesource.com/2189976
Branch: androidx-main
commit c73bd92631a2ff341f89001bc9143c7b998333e8
Author: Sanura N'Jaka <sanura@google.com>
Date: Thu Aug 18 18:03:13 2022
Add project dependency constraint between lifecycle-viewmodel and lifecycle-viewmodel-savedstate
Added bi-directional project version constraint between
lifecycle-viewmodel and lifecycle-viewmodel-savedstate.
If both artifacts are in the dependency tree, their
versions should match. This will now be enforced by gradle
automatically bumping up either version to meet constraint.
Test: N/A
Bug: 242871265
Change-Id: I3ab2abf9b6b1861038afc0e651da80e4ee75efb8
M lifecycle/lifecycle-viewmodel-savedstate/build.gradle
he...@gmail.com <he...@gmail.com> #3
Project: platform/frameworks/support
Branch: androidx-main
commit e7a81dc92c9c56b31455c75161a8becf49f761e3
Author: Sanura N'Jaka <sanura@google.com>
Date: Wed Aug 17 22:44:55 2022
Add project dependency constraint between lifecycle-runtime and lifecycle-runtime-compose
Added bi-directional project version constraint between
lifecycle-runtime and lifecycle-runtime-compose. If both
artifacts are in the dependency tree, their versions
should match. This will now be enforced by gradle
automatically bumping up either version to meet constraint.
Test: N/A
Bug: 242871265
Change-Id: I0f6b3928ac0b338b0fcc6835828dd43fadee8c0d
M lifecycle/lifecycle-runtime-compose/build.gradle
M lifecycle/lifecycle-runtime/build.gradle
https://android-review.googlesource.com/2189951
Branch: androidx-main
commit e7a81dc92c9c56b31455c75161a8becf49f761e3
Author: Sanura N'Jaka <sanura@google.com>
Date: Wed Aug 17 22:44:55 2022
Add project dependency constraint between lifecycle-runtime and lifecycle-runtime-compose
Added bi-directional project version constraint between
lifecycle-runtime and lifecycle-runtime-compose. If both
artifacts are in the dependency tree, their versions
should match. This will now be enforced by gradle
automatically bumping up either version to meet constraint.
Test: N/A
Bug: 242871265
Change-Id: I0f6b3928ac0b338b0fcc6835828dd43fadee8c0d
M lifecycle/lifecycle-runtime-compose/build.gradle
M lifecycle/lifecycle-runtime/build.gradle
Description
Version used:1.1.1
Devices/Android versions reproduced on: All
File: FrameworkSQLiteOpenHelper
FrameworkSQLiteDatabase getWrappedDb(SQLiteDatabase sqLiteDatabase) {
FrameworkSQLiteDatabase dbRef = mDbRef[0];
if (dbRef == null) {
dbRef = new FrameworkSQLiteDatabase(sqLiteDatabase);
mDbRef[0] = dbRef;
}
return mDbRef[0];
}
Room always preserve The First Open db, even if it is closed.
Sometimes sqLiteDatabase != mDbRef[0].mDelegate, we get the wrong db from room.
This occurs when opening db, then something wrong and throws exception, but app caught it. The next time we use room, it throws re-open exception.
I thinks mDbRef[0].mDelegate should change when sqLiteDatabase is changed.
Like this:
FrameworkSQLiteDatabase getWrappedDb(SQLiteDatabase sqLiteDatabase) {
FrameworkSQLiteDatabase dbRef = mDbRef[0];
if (dbRef == null || dbRef.isDatabaseChanged(sqLiteDatabase)) {
dbRef = new FrameworkSQLiteDatabase(sqLiteDatabase);
mDbRef[0] = dbRef;
}
return mDbRef[0];
}
File: FrameworkSQLiteDatabase
public boolean isDatabaseChanged(SQLiteDatabase db) {
return mDelegate != db;
}