Open user1823 opened 7 months ago
Idk if this is a 2.16 or 2.17 bug, but I have been experiencing this eventually since a reasonable amount of time
A debug setting here would be useful: potentially either walk the stack, or accept a user-supplied debug string to display on the dialog
I suspect this is loadCounts
, but we should be able to know the cause
Lazy code which gets a good debug string
Exception().stackTraceToString().split("\n").reversed().takeWhile { !it.contains("launchCatchingTask") && !it.contains("withProgress") }.reversed().take(7).joinToString("\n")
awaitBackupCompletion() can be moved out of withCol() and called via getBackend().awaitBackupCompletion() instead, which will prevent other collection ops from blocking while a backup completes.
@david-allison, I still see random popups appearing on the screen for a fraction of second (for such a small amount of time that I can only see a flash). Today, I noticed that there is a backup created at the same time. So, I think that these popups are due to automated backups.
AnkiDroid version 2.18 alpha 6
Recently (most probably since 2.19 alpha 6), the frequency of the "Processing" popups has increased. A popup appears almost every time I launch the app. These popups don't seem to be associated with automated backups because there is no backup created at the same time.
With alpha 6, I am using the old directory location (/storage/emulated/0/AnkiDroid) because I had to uninstall and then reinstall the app after I installed alpha 5 which had a bug making it impossible to launch.
Can the recent increase in the frequency of these popups be caused by a shift from the new location (/storage/emulated/0/Android/data/com.ichi2.anki/files/AnkiDroid) to the old location?
In http://github.com/ankidroid/Anki-Android/wiki/Storage-Migration-FAQ, I read
If AnkiDroid 2.16 is using the new location ... file operations (media sync, import etc...) are much faster
So, maybe, the slow reading of the collection file from the old location is causing these "Processing" popups to appear?
Edit: I switched back to the new directory location and I am still seeing the problem. So, the directory location was not the cause.
While using the app, a popup saying "Processing" randomly appears on the screen.
I suspect this indicates that AnkiDroid is creating a backup. If it is so, either this should occur in the background (if possible) or the popup should clearly say "Creating a backup". Otherwise, it's not clear what it is "processing".