Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Root namespace default tasks ignored #165
In the following setup:
@task(default=True) def all_the_things(): # whatever # this bug is true for implicit and explicit root namespaces - makes no difference
This command should call
But it doesn't; nor does it error.
If we have code that does/did do this, figure out why it broke & write regression test.
If not, update things so it does.
Torn between this being the responsibility of the parser ("Got nothing, assume I got the default task's name") and the CLI module ("Got no tasks/contexts back from the parser, let's ask the collection for its default and pretend that was given").
Implementation wise, it's significantly easier to do it at the CLI module; the parser doesn't know or care about default tasks per se - we just use name aliasing and Lexicons for that - but that doesn't map well to "emptiness" because it's all about parsing text tokens.
Whereas the CLI module has ready, clean access to both the parser result and the collection object.