csicar/Ning

connectionInfo.bssid must not be null

Closed this issue · 2 comments

2021-01-08 12:15:45.493 8983-8983/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: de.csicar.ning, PID: 8983
java.lang.NullPointerException: connectionInfo.bssid must not be null
at de.csicar.ning.ScanRepository$startScan$2.invokeSuspend(ScanRepository.kt:38)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)
2021-01-08 12:15:52.169 9012-9095/? E/SQLiteLog: (1) no such table: EmailMessage_com.google.android.gm_seq_table
2021-01-08 12:15:52.171 9012-9095/? E/Icing: Cursor call threw an exception: no such table: EmailMessage_com.google.android.gm_seq_table (code 1): , while compiling: SELECT * FROM [EmailMessage_com.google.android.gm_seq_table] WHERE seqno>0 AND tag IS NULL ORDER BY seqno LIMIT 20
#################################################################
Error Code : 1 (SQLITE_ERROR)
Caused By : SQL(query) error or missing database.
(no such table: EmailMessage_com.google.android.gm_seq_table (code 1): , while compiling: SELECT * FROM [EmailMessage_com.google.android.gm_seq_table] WHERE seqno>0 AND tag IS NULL ORDER BY seqno LIMIT 20)
#################################################################
2021-01-08 12:15:52.173 9012-9095/? E/Icing: Aborting indexing of corpus internal.3p:EmailMessage

Could you elaborate: What version of Ning and Android are you using?

On master this should no longer be a problem. You can test that by installing the pre-release: https://github.com/csicar/Ning/releases/tag/v1.2.5-alpha-1

Ning now checks whether bssid is null so this issue should not occur anymore
See:

val bssid = if (connectionInfo == null) null else MacAddress(connectionInfo.bssid)