Repository navigation
Conversation
A boolean flag (is_flag=True) consumes no value, so matching it as the last token must not short-circuit completion of the remaining parameters. Previously the completer returned nothing after a flag; now it continues offering the command's other options and arguments while still not offering true/false for the flag itself. - _completer.py: skip the param_called/break short-circuit for flags - tests: assert completion continues after a flag (options + arguments) - Changelog: add entry
|
@charan-rathore would you mind trying and reviewing it? |
|
Tried it locally. On master, completing after a boolean flag returns nothing: |
then why the tests are failing in the CI? |
|
Checked the failing job: it is the flake8 tox env, not the tests (click81/82/83 all pass). One lint error: tests/test_completion/test_common_tests/test_option_completion.py:59 is 93 chars, over the 90 limit (E501). I reproduce it locally with |
A boolean flag (is_flag=True) consumes no value, so matching it as the last token must not short-circuit completion of the remaining parameters. Previously the completer returned nothing after a flag; now it continues offering the command's other options and arguments while still not offering true/false for the flag itself.
Fix #142