My biggest pet peeve with pyinvoke is that you can’t pass arbitrary arguments through to the underlying task. For something like invoking pytest you need to replicate the arguments you use in the task definition.
Yup! I totally get that as I ran into it the first time I used pyinvoke. I got around this limitation by using pyinvoke to just specify the tasks, their arguments and what other tasks they rely on, and let the tasks that share arguments delegate their core to the common function. It is an inconvenience, so I was planning on contributing this missing feature upstream to the library.