Day events and --notstarted
Not sure if this is intended behaviour, but currently I have a day event for today:
❯ khal list
Today, 2021-01-13
test ⟳
and I would expect that by doing:
❯ khal list --notstarted now 30m
would filter out the already-started event, but the output is the same.
I just checked it happens also for non-recurring events
I think is is a normal beavior, Khal documentation say:
With the
–notstartedoption only events are shown that start after START.
And when you don't specify a start date 'khal` assume that it is the present day at 0:00 and show your test event. I will test it more tomorrow,
Hmm but if it started at 00:00, the it is already started, so why should it be included with -notstarted?
@mredaelli I think there is a bug with allday event at this level, I'm going to test it this evening an push a Merge Request if needed.
@mredaelli For me, there is no problem with normal events, khal as it should. But for all day event not. In my opinionkhal should not display the current day event when you do khal list even without now> Here is the code:
https://github.com/pimutils/khal/blob/2bbea841a4320bfa26c25a9918f5658d31e870cb/khal/controllers.py#L188-L191
I'll submit a draft MR to avoid the issue in minutes.
In my opinion
khalshould not display the current day event when you dokhal listeven withoutnow> Here is the code:
I disagree with this part. It's in line with the documented behaviour. Changing this also prevents excluding multi-day events (that have started before the chosen day) but showing new events on that day.
since #1005 looks like it may end up being quite complex to implement - what is the best way to get the next event via Khal when you have an all-day event? Is there one?
E.g. if I have an event coming up in the next 15m, do I have to do khal list and parse out any all-day events from the results manually?