Change theme
Help
Press space for more information.
Show links for this issue (Shortcut: i, l)
Copy issue ID
Previous Issue (Shortcut: k)
Next Issue (Shortcut: j)
Sign in to use full features.
Vote: I am impacted
Notification menu
Refresh (Shortcut: Shift+r)
Go home (Shortcut: u)
Pending code changes (auto-populated)
View issue level access limits(Press Alt + Right arrow for more information)
Unintended behavior
View staffing
Description
Version used: 2.7.0-alpha11
Devices/Android versions reproduced on: iPhone 13 mini iOS 18.0.1
I am currently turning my Android app into a KMP app.
I have a BaseDao class that other classes inherit from. When calling the 'deleteWorkoutSets' function I get the following Error: SQLiteException: Error code: 8, message: attempt to write a readonly database
abstract class SetBaseDao<T : BaseEntity> constructor(
tableName: String
) : BaseDao<T>(tableName) {
suspend fun deleteWorkoutSets(reference: Int) {
executeRawQuery(RoomRawQuery("DELETE FROM $tableName WHERE reference = $reference"))
}
}
When moving the function directly into the classes that inherited the function it works without problems.
@Query("DELETE FROM $TABLE WHERE reference = :reference")
abstract override suspend fun deleteWorkoutSets(reference: Int) // in class that previously inherited the function
abstract suspend fun deleteWorkoutSets(workoutIdReference: Int) // in SetBaseDao
I am not sure if this is a bug or if I missed some documentation somewhere. All I know is that it worked for my Android app but had to be adjusted for the KMP one and I thought I would document it in case someone else runs into a similar problem or if it is indeed a bug that someone can have a look at it.
Best
Corey