K1rakishou / Kuroba-Experimental

Free and open source image board browser

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Foreground Thread Watcher can be inconsistent

lewri opened this issue · comments

I've noticed at times that the thread watcher doesn't always reliably go off and check your bookmarked threads when the app is open and in use. This is also the case where setting the poll interval to 30s. Adaptive interval is off.

Sometimes the watcher only seems to go check one of two threads, while others get new posts but aren't updated at all.
If you fully close down the app and reopen it you can see that it will properly poll all bookmarked threads.

Version 1.3.33.0

Would be nice to see logs. Maybe there is a silent crash happening when one of the bookmarks is updated which then prevents other bookmarks from being updated.

Here's some logs
logs.txt

Edit: I actually just noticed one thread actually failed to update the bookmark on launch. A reply came in an hour ago and was never detected.

BookmarkWatcherDelegate: doWorkInternal() updating 1 bookmarks

So, according to the logs only one bookmark is being updated: a bookmark for a thread that you are currently viewing. There is supposed to be another updater working when the app is in foreground for other active bookmarks but I don't see it in the logs so it's probably not working.

So far it looks like foreground updater got stopped (which is fine when you minimize the app, for example) but wasn't restarted again for some reason.

Can you try adding a new bookmark and then checking if it fixes anything? Also, can you enable verbose logs in the developer settings before that?

Ok I have added foreground watcher restarting logic in two more places so it shouldn't be completely killed anymore.
Try the latest beta once it's done building.

Okay that change appears to be working better now 👍

Can you try adding a new bookmark and then checking if it fixes anything?

To confirm new bookmark woke up the watcher to execute

Okay, then will try to make a stable release today.