You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
todo list --start before 2023-03-01 results in the following error:
Traceback (most recent call last):
File "/usr/bin/todo", line 8, in <module>
sys.exit(cli())
File "/usr/lib/python3.10/site-packages/click/core.py", line 1130, in __call__
return self.main(*args, **kwargs)
File "/usr/lib/python3.10/site-packages/click/core.py", line 1055, in main
rv = self.invoke(ctx)
File "/usr/lib/python3.10/site-packages/click/core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/lib/python3.10/site-packages/click/core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/lib/python3.10/site-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "/usr/lib/python3.10/site-packages/click/decorators.py", line 84, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
File "/usr/lib/python3.10/site-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "/usr/lib/python3.10/site-packages/todoman/cli.py", line 38, in wrapper
return f(*a, **kw)
File "/usr/lib/python3.10/site-packages/todoman/cli.py", line 658, in list
click.echo(ctx.formatter.compact_multiple(todos, hide_list))
File "/usr/lib/python3.10/site-packages/todoman/formatters.py", line 69, in compact_multiple
for todo in todos:
File "/usr/lib/python3.10/site-packages/todoman/model.py", line 795, in todos
dt = dt.timestamp()
AttributeError: 'datetime.date' object has no attribute 'timestamp'. Did you mean: 'fromtimestamp'?
It works as expected if the time is specified, i.e.: todo list --start before 2023-03-01T10:00
Proposal: The start parameter should fallback to a default time, i.e. "00:00:00".
Furthermore the --start parameter should be documented correctly:
Currently no [before|after] is described in the documentation and zsh completion.
Version: todoman, version 4.2.1
The text was updated successfully, but these errors were encountered:
Indeed, we should allow dates here. I think _validate_start_date_param should return Tuple[bool, datetime] | Tuple[bool, date] | None (it currently returns Tuple[bool, datetime] | None).
The docs should also definitely reflect the before/after usage.
todo list --start before 2023-03-01
results in the following error:It works as expected if the time is specified, i.e.:
todo list --start before 2023-03-01T10:00
Proposal: The start parameter should fallback to a default time, i.e. "00:00:00".
Furthermore the
--start
parameter should be documented correctly:Currently no
[before|after]
is described in the documentation and zsh completion.Version:
todoman, version 4.2.1
The text was updated successfully, but these errors were encountered: