sexp-read goes back to not splitting events, not even when they cross
the provided timestamps. Splitting events is left to data consuming
functions via events-maybe-split, since not all of them need it. (e.g.
history generation for tags/keys/values)
Created
filter-events-time
Create
ts->iso
filter-task-events
Update
events-maybe-split to use ts.el
active-time-one-day to use ts.el
day-start to use ts.el
midnight-spanning-p to use ts.el
statistics-count-average-time-spent to use filter-events-task
Move
day-start from events.el to time.el
midnight-spanning-p from time.el to events.el
Remove
task-events-in-day (repalced by filter-events-task)
This was causing chronometrist-sexp-last to return nil, and the
ignore-errors was, well, ignoring-errors, resulting in all sorts of
mysterious bugs.
Added a test to prevent it from happening again.
1. chronometrist-events->time-list -> chronometrist-events->ts-pairs,
now returns a list of ts pairs. Rewritten using cl-loop.
2. chronometrist-time-list->sum-of-intervals ->
chronometrist-ts-pairs->durations, now returns a list of durations in
integer seconds.
3. A critical bug in chronometrist-iso-timestamp->ts was discovered -
we were passing the output of encode-time (via
parse-iso8601-time-string) to (make-ts :unix ...) - the latter expects
a number, not a list.
4. Both chronometrist-task-time-one-day and
chronometrist-events->ts-pairs were checking if a task was still
ongoing. Removed the redundant checking from the former.
5. Updated docstring of chronometrist-active-time-one-day
6. chronometrist-statistics-count-average-time-spent rewritten using
cl-loop
Also, when trying to write tests, I realized that
chronometrist-events-clean has long been removed. Removed a reference
to it from the manual and a docstring.
seconds-to-hms now returns a list instead of a vector.
chronometrist-format-time now takes integer seconds instead of lists
or vectors.
manual - remove types which are no longer used
Removed unused functions
chronometrist-time-interval-span-midnight?
chronometrist-time-add
seconds-to-hms now returns a list instead of a vector.
chronometrist-format-time now takes integer seconds instead of lists
or vectors.
manual - remove types which are no longer used
Removed unused functions
chronometrist-time-interval-span-midnight?
chronometrist-time-add
It was much too spaced out, for no benefit I could perceive.
Also, we remove the interactive spec from query-stop. There's no need
for it to appear in the execute-extended-command menu.
Changing chronometrist-date requires changing task-events-in-day,
because the latter expected "YYYY-MM-DD" and chronometrist-date was
used to provide that.