ActivityWatch / activitywatch

The best free and open-source automated time tracker. Cross-platform, extensible, privacy-focused.
https://activitywatch.net/
Mozilla Public License 2.0
11.34k stars 512 forks source link

0s activity #1006

Open lucianosarno opened 6 months ago

lucianosarno commented 6 months ago

Describe the bug

For today (Jan-10) dashboard just shows 0s activity.

To Reproduce

Additional context

github-actions[bot] commented 6 months ago

Hi there! As you're new to this repo, please make sure you've used an appropriate issue template and searched for duplicates (it helps us focus on actual development!). We'd also like to suggest that you read our contribution guidelines and our code of conduct. Thanks a bunch for opening your first issue! 🙏

wonka929 commented 5 months ago

This bug desciption is awful. I will continue with this bug bringing some light.

So, the issue was similar to an old one https://github.com/ActivityWatch/activitywatch/issues/190

Schermata del 2024-01-25 12-50-04 Schermata del 2024-01-25 12-48-57 query_22_gen.har.zip

I'm trying to visualize the activity summary for day 22 gen and it does not seem it's able to do so (same for 23).

What i've tested:

No changes except that if i pu start of day at 00:00 insteaf of 4:00 i can see the activities from 0:00 to 2:00 but not everything else.

I have also parsed the Chrome Har file with the activity in Network page of developer. The query from Chrome clearly shows it can get all the activities of the day, but something happen probably during the merging process.

As such, i've seen both python and rust server log (attached to this comment) and i see many of these lines:

[2024-01-25 12:44:51][WARN][aw_transform::flood]: Gap was of negative duration and could NOT be safely merged (-PT1407.768Ss). This warning will only show once per batch. [2024-01-25 12:44:51][WARN][aw_transform::flood]: Gap was of negative duration (-PT255.328391Ss), but could be safely merged. This error will only show once per batch.

aw-server-rust.zip aw-server_2024-01-25T12-16-40.zip

Seems like there is an error involving negative times, without particular reason for it.