Activity for current day not displaying on Activity tab

Hello, I am using ActivityWatch v 0.9.2 (latest release download on Github) on Kubuntu (based on Ubuntu 19.10 eoan). In general the software is working very well for me on this desktop, my Debian laptop, and my Android smartphone. However I noticed that today when I try to look at my Activity tab for today, there’s absolutely no data displaying. Even after restarting my computer several times it doesn’t seem like it is fixing the issue and allowing it to start tracking my usage again. From just the Activity tab, it seems like I haven’t used the computer at all today despite using it for several hours!

However, when I went to the Query and Timeline tabs, by setting the time range for at least a day or two (i.e. it is currently Sept. 11, so I set it to Sept. 10 to Sept. 12 just to over estimate a bit) I see that it actually has logged all of my activity for today. And in fact, if I go to the Activity tab and show data for the whole week everything shows up. One thought I had was that maybe, due to some error, it was just being tracked under Sept. 10 for some reason but the data doesn’t show up there either.

I’ve only just started using this program a couple weeks ago and haven’t really bothered to look at the development notes for it, since I’m not particularly interested in contributing code at the moment, so I’m not really sure where to start looking. The only potentially suspicious thing I can find is that the afk-watcher claims I have been not-afk since 9am yesterday (on Sept. 10) even during periods where I have power cycled the machine or terminated the aw- processes in my system viewer. At first I thought this might have had something to do with extending the afk timeout in aw-watcher-afk.ini but I did the same thing on my laptop and it seems to not be having the same problem. And in fact, this isn’t the first time I’ve had an extended not-afk period on my desktop due to not shutting it down before, so I’m not really sure what the issue is.

I am probably going to shut my desktop off for the rest of the night while I go to work in the hope that it will maybe trip past the current day and reset when I turn it on again, but I’m not sure how to resolve it if that doesn’t work. If anyone has any advice or knows of this problem happening to any other users, I would appreciate hearing about it! Thanks :slight_smile:

So I did leave my desktop off for the whole night until now. The problem is half resolved, because as soon as I checked ActivityWatch for today (September 12) I immediately saw new activity building up on the Activity tab. Then I went back a day… and no, it still doesn’t show any activity for all of Sept. 11. I even went back to Sept. 10 and it’s still not being counted as data under that date (which I guess is actually good, it means that the program knows well enough not to taint one day’s data with another even in a situation like this).

Here is just a picture of my overview on the Timeline tab:

Two things jump out: 1) There are clearly items that were tracked for Sept. 11 and 2) something seems kind of wacky about how the not-afk status was reported. The timestamp on that bar says 2020-09-10T9:18:52-04:00 but it’s also saying that this block of time accounts for 32h 10m 10s of time. From looking at my laptop, it seems like it is somehow able to correctly sense the passing of the day mark and so will chop afk statuses at that time and start a new block.

Upon seeing this happen, I went back and looked at some older data:

So you’ll see, over on Sept. 3 I had another not-afk block happen that started at 10:33 (whenever I turned on my computer for that day) that lasted for 48h 50m 4s. This means it easily stretches into Sept. 4 and Sept. 5. I had originally thought that the data was reported for these days, but it turns out that when looking back there’s nothning on the activity tabs. Sept. 11 also shown for clarity.

It should be noted that Sept. 3, Sept. 6, Sept. 10, and Sept. 12 (the adjacent days) all display data normally. The specific items reported in the timeline also show up on the weekly summary on the Activity tab. But for some reason, probably because of this overflow from one day to the next of the not-afk status, it seems unable to parse out the items for days after that overflow begins.

So obviously, the answer here seems to be either to reduce my afk timeout again (which I would rather not do) and/or to shut off my computer when I am done using it at a set period of time especially close to the day cutoff (which I probably will start doing more frequently). However I would also like to know if there are any other ways I could fix this, or if this is even something I have to report as an issue on the Github or something?

Any help or insight would be appreciated, thanks :slight_smile:

There’s a lot to reply to here and I don’t have time to break down everything, but here’s some thoughts:

The only potentially suspicious thing I can find is that the afk-watcher claims I have been not-afk since 9am yesterday (on Sept. 10) even during periods where I have power cycled the machine or terminated the aw- processes in my system viewer.

That’s very weird, I haven’t seen that being an issue in years.

From looking at my laptop, it seems like it is somehow able to correctly sense the passing of the day mark and so will chop afk statuses at that time and start a new block.

There’s a catch here. The “day mark” is actually at 04:00 by default, so it will handle events across 00:00 fine, as long as they end before 04:00. However, events that stretch past 04:00 will cause issues. The issue is tracked here:

1 Like

Alright, excellent. Yeah that issue seems to be basically what I am experiencing, so that makes sense why it would end up being a problem. Overall the software is very good, and the fact that all the data gets reported correctly in the weekly summaries is definitely the most important part to me. I just wanted to make sure this was brought up for you and other users to be aware of :slight_smile:

Have a good day!