pipx
pipx copied to clipboard
flag for app considered ambiguous option to pipx run
Describe the bug
some flag arguments are not possible to provide to the app as they seem to be checked for use with run
instead of the APP
How to reproduce
$ pipx --verbose run --spec kfp-tekton dsl-compile-tekton --py pipeline.py --output pipeline.yaml
usage: pipx run [-h] [--no-cache] [--pypackages] [--spec SPEC] [--verbose] [--python PYTHON] [--system-site-packages] [--index-url INDEX_URL]
[--editable] [--pip-args PIP_ARGS]
app ...
pipx run: error: ambiguous option: --py could match --pypackages, --python
Expected behavior any and every flag to be passed to APP directly
You need to add --
to prevent the options from being interpreted as one to pipx run
. This is how argument parsing works.
pipx --verbose run --spec kfp-tekton -- dsl-compile-tekton --py pipeline.py --output pipeline.yaml
Thanks for the fast response!
This was not clear to me from the docs,
positional arguments: app ... app/package name and any arguments to be passed to it
implied to me that the arguments need no special treatment.
Thanks for the feedback. Let’s take this as an opportunity to improve the docs. PRs welcome.