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
I installed todoman yesterday (version 1.6.0); after getting it to read my vdir the list command fails to list my todos; it throws
Traceback (most recent call last):
File "/usr/local/bin/todo", line 11, in <module>
sys.exit(cli())
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 716, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 696, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1037, in invoke
return Command.invoke(self, ctx)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/todoman/cli.py", line 64, in cli
ctx.invoke(cli.commands["list"])
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/todoman/cli.py", line 232, in list
reverse=reverse
TypeError: other argument must be K instance
[0, False, inf, <functools.KeyWrapper object at 0x7fd9f2cd1970>]
[0, False, inf, <functools.KeyWrapper object at 0x7fd9f2cd18f0>]
...
[<functools.KeyWrapper object at 0x7fd9f2cd19b0>, False, inf, <functools.KeyWrapper object at 0x7fd9f2cd1990>]
which causes the comparison to fail when the first and last todos are compared, since the first element is of a different type. The first element is for the priority field (main.py#L40); because it is a "negative" field it enters the main.py#L73 condition. I believe the fix should be to change the condition to if neg, in order to allow the comparison to occur. I've PR'd in #25, please check it and see if I'm understanding this correctly. Tell me if you need any sample data or more info.
And thank you very much for developing and maintaining todoman, I was looking for a CLI todo manager for a while!
The text was updated successfully, but these errors were encountered:
Thanks for tracking down the issue. I recently added a unit test, that exposes this bug (currently, master is failing due to it), but failed horribly to track down what was causing it.
I installed
todoman
yesterday (version 1.6.0); after getting it to read myvdir
thelist
command fails to list my todos; it throwsBy printing the value of
rv
(main.py#L82) we getwhich causes the comparison to fail when the first and last todos are compared, since the first element is of a different type. The first element is for the
priority
field (main.py#L40); because it is a "negative" field it enters the main.py#L73 condition. I believe the fix should be to change the condition toif neg
, in order to allow the comparison to occur. I've PR'd in #25, please check it and see if I'm understanding this correctly. Tell me if you need any sample data or more info.And thank you very much for developing and maintaining
todoman
, I was looking for a CLI todo manager for a while!The text was updated successfully, but these errors were encountered: