Google Analytics SDK 10.2.0 has StrictMode violations
Asked Answered
C

1

7

I have nowhere to report this but here, as the issue tracker is read-only: https://code.google.com/p/analytics-issues/issues/list

When running with StrictMode enabled I get the following from the Google Analytics SDK v10.2.0:

02-16 10:55:46.245 2633-2641/com.visiolink.reader.wrapper E/StrictMode: Finalizing a Cursor that has not been deactivated or closed. database = /data/user/0/com.visiolink.reader.wrapper/databases/google_app_measurement_local.db, table = null, query = select count(1) from messages
                                                                        android.database.sqlite.DatabaseObjectNotClosedException: Application did not close the cursor or database object that was opened here
                                                                            at android.database.sqlite.SQLiteCursor.<init>(SQLiteCursor.java:98)
                                                                            at android.database.sqlite.SQLiteDirectCursorDriver.query(SQLiteDirectCursorDriver.java:50)
                                                                            at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1316)
                                                                            at android.database.sqlite.SQLiteDatabase.rawQuery(SQLiteDatabase.java:1255)
                                                                            at com.google.android.gms.internal.zzatv.zza(Unknown Source)
                                                                            at com.google.android.gms.internal.zzatv.zza(Unknown Source)
                                                                            at com.google.android.gms.internal.zzaul.zzc(Unknown Source)
                                                                            at com.google.android.gms.internal.zzauj.zzb(Unknown Source)
                                                                            at com.google.android.gms.internal.zzauj.zza(Unknown Source)
                                                                            at com.google.android.gms.internal.zzauj$8.run(Unknown Source)
                                                                            at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:423)
                                                                            at java.util.concurrent.FutureTask.run(FutureTask.java:237)
                                                                            at com.google.android.gms.internal.zzaud$zzd.run(Unknown Source)
Cosmism answered 16/2, 2017 at 10:9 Comment(0)
S
1

I had the exact same problem with Firebase and it appears to be fixed in version 11.0.1. so try updating your dependencies

Scully answered 8/8, 2017 at 10:59 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.