Replace pyinvoke with Makefile #233
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
pyinvoke has several serious issues. First and foremost, it is very unsafe to pass any string arguments to
run(), because it does not verify the string arguments at all. Given this function intasks.py:you can get quite interesting results:
❯ invoke hello user ❯ invoke hello --name="; date" Sat Oct 18 11:41:56 CEST 2025This is an issue number 2 in pyinvoke and I can't see it closed in any foreseeable future:
pyinvoke/invoke#2
Additionally, running linters from
invoke.run()disables any colors from the linters which makes it less comfortable to use and caused us to force colors in some targets:6111059
Even with that change, I have to pass additional
-cany time I would like to run linters with colored output.Considering these main issues, I have considered different alternatives to pyinvoke with one of them being
tox:#106
However,
toxseems to be somewhat of an overkill for such a simple task, and also packaging was done viainvokeas well. Therefore I've decided to pickmakeas an alternative.This commit replaces
tasks.pywith a correspondingMakefile, removesinvokefromdevdependencies (additionally removingclickthat was mentioned there explicitly for some reason) and replaces all the calls forinvokewith calls formake.This PR closes #62
Pull Request check-list
Description of change