Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Report tasks over midnight #29

Open
michelepagot opened this issue Oct 13, 2023 · 2 comments
Open

Report tasks over midnight #29

michelepagot opened this issue Oct 13, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@michelepagot
Copy link

Someone could say that midnight is usually a good moment not to be at the keyboard and sleep...

Apart from this

2023-10-12 18:45 - 2023-10-12 18:50 | difficult_prj | Doing something long
2023-10-12 23:31 - 2023-10-13 00:09 | difficult_prj | Doing something long
2023-10-13 00:10 - 2023-10-13 01:13 | difficult_prj | Doing something long

At 00:09 I run bartib report --today and the response was not ok. (so I stopped and started it to attempt to understand what was going on)

I'm not sure what to ask here, is there a bug when we cross date? maybe we can add --last24 near of --today ?

@nikolassv
Copy link
Owner

Thank you for raising the issue! You are right: reports for activities that span multiple days could use some refinement. Currently, each activity is reported for the date it began.

One potential solution could be to provide an option for reporting activities over a more specific time period, such as the last 24 or 12 hours. However, the fundamental issue remains the same: how should we handle activities that are active during the reporting period but begin before or extend beyond it?

Perhaps the optimal solution is to include all activities in a report that are active during the reporting period, but adjust their duration. For instance, if an activity lasts for one and a half hours but began half an hour before the reporting period, we would report it with a duration of one hour. Ideally, we should also mark these truncated activities in some way to indicate that they have been adjusted.

What are your thoughts on this approach?

@nikolassv nikolassv added the enhancement New feature or request label Oct 25, 2023
@michelepagot
Copy link
Author

michelepagot commented Oct 30, 2023

I like the idea to simply truncate intervals crossing the requested repo boundary.
About marking such situation in the report, I see it like an accessory idea, not bad or wrong but maybe not strectly needed.
About reporting the last 24h instead of using the calendar day, I think that as user I like to have this feature aside the current --today and --yesterday and not as a replacement for them.

P.S. Bartib is amazing, I'm using it daily in the last 3 weeks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants