No such column: genre nor genre_id #32
Labels
P: Android
Only android platform
PRI: High
Needs to be resolved sooner than other issues (Critical to plugin function)
T: Bug
Something isn't working
https://github.com/LucasPJS/on_audio_query/blob/026501548a108808a863167b0e94dad4967fbb56/on_audio_query/android/src/main/kotlin/com/lucasjosino/on_audio_query/query/OnAudiosQuery.kt#L81
https://github.com/LucasPJS/on_audio_query/blob/026501548a108808a863167b0e94dad4967fbb56/on_audio_query/android/src/main/kotlin/com/lucasjosino/on_audio_query/utils/OnCursorProjections.kt#L28
https://github.com/LucasPJS/on_audio_query/blob/026501548a108808a863167b0e94dad4967fbb56/on_audio_query/android/src/main/kotlin/com/lucasjosino/on_audio_query/utils/OnCursorProjections.kt#L29
I think we need to check the SDK version before using those?
the error occurs on android 9.0.
E/AndroidRuntime( 9376): android.database.sqlite.SQLiteException: no such column: genre (code 1 SQLITE_ERROR): , while compiling: SELECT _data, _display_name, _id, _size, album, album_artist, album_id, artist, artist_id, bookmark, composer, date_added, date_modified, duration, title, track, year, genre, genre_id, is_alarm, is_audiobook, is_music, is_notification, is_podcast, is_ringtone FROM audio ORDER BY date_added DESC
E/AndroidRuntime( 9376): at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:179)
E/AndroidRuntime( 9376): at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:135)
E/AndroidRuntime( 9376): at android.content.ContentProviderProxy.query(ContentProviderNative.java:418)
E/AndroidRuntime( 9376): at android.content.ContentResolver.query(ContentResolver.java:802)
E/AndroidRuntime( 9376): at android.content.ContentResolver.query(ContentResolver.java:752)
E/AndroidRuntime( 9376): at android.content.ContentResolver.query(ContentResolver.java:710)
E/AndroidRuntime( 9376): at com.lucasjosino.on_audio_query.query.OnAudiosQuery$loadSongs$2.invokeSuspend(OnAudiosQuery.kt:81)
E/AndroidRuntime( 9376): at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
E/AndroidRuntime( 9376): at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
E/AndroidRuntime( 9376): at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
E/AndroidRuntime( 9376): at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
E/AndroidRuntime( 9376): at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
E/AndroidRuntime( 9376): at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)
I/Process ( 9376): Sending signal. PID: 9376 SIG: 9
flutter version
: Flutter 2.5.1 • channel stable • https://github.com/flutter/flutter.gitFramework • revision ffb2ecea52 (9 days ago) • 2021-09-17 15:26:33 -0400
Engine • revision b3af521a05
Tools • Dart 2.14.2
package version
: ^2.3.0The text was updated successfully, but these errors were encountered: