AFK and window watcher suddenly stopped logging
See original GitHub issueI have no idea what caused this, but they both stopped logging on the same day.
My last window event was at 2018-01-19T07:47:07.749000+00:00 (+7s duration) and my last AFK event was at 2018-01-19T17:23:51.631000+00:00 (+7min duration).
The logs for aw-watcher-afk show nothing weird (just a bunch of “Became AFK”/“No longer AFK” messages), but the aw-watcher-window looks a bit weird at least.
2018-01-17 16:09:10 [INFO ]: Running watcher with poll time 1.0 seconds (aw_watcher_window.main:35)
2018-01-17 16:09:10 [INFO ]: aw-watcher-window has started (aw_watcher_window.main:44)
2018-01-17 16:09:20 [INFO ]: Connection to aw-server established (aw_client.client:281)
2018-01-17 16:09:20 [INFO ]: Loaded 11 failed requests from queuefile (aw_client.client:266)
2018-01-20 17:48:22 [WARNING]: Failed to send request to aw-server, will queue requests until connection is available. (aw_client.client:305)
2018-01-20 17:48:43 [INFO ]: Connection to aw-server established (aw_client.client:281)
2018-01-20 17:48:43 [INFO ]: Loaded 55285 failed requests from queuefile (aw_client.client:266)
I find it weird that all those failed requests were loaded from the queuefile yet the log doesn’t say anything events not getting through to the server? Perhaps something that should have ended up in the log didn’t? (Such as a thread crash)
The 2018-01-20 17:48 messages were around the time when I noticed and then restarted aw-server. I then shortly after restarted aw-watcher-window which probably lead to all the events being lost because they did not get sent after restart. Probably an issue in the failed request queue that needs fixing.
Issue Analytics
- State:
- Created 6 years ago
- Comments:12 (12 by maintainers)

Top Related StackOverflow Question
Been running master + the persist-queue PR for aw-client for a while now and the issue persists. However, with the persist-queue PR I can now at least manually restart the watchers (causing the queue to empty at a good pace) without losing any data, so that’s nice.
By looking at the RequestQueue in aw-client I can easily see a couple of possible race conditions, we should probably take a look at the implementation again.