Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🗑️ Deprecate shell_complete and continue to use autocompletion for CLI parameters #974

Merged
merged 12 commits into from
Dec 4, 2024
Prev Previous commit
Next Next commit
fix
  • Loading branch information
svlandeg committed Sep 5, 2024
commit e17a0f56bd05effcaaafcec6263fddd84d3a4098
2 changes: 1 addition & 1 deletion docs/tutorial/options-autocompletion.md
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ It doesn't matter how you name them, in which order, or which ones of the 3 opti

Note that Click 7 had a similar [`autocompletion` function](https://click.palletsprojects.com/en/7.x/bashcomplete/), but it worked slightly differently.

It required the callback function to take exactly the 3 keyword arguments `ctx`, `args` and `incomplete` in that exact order, instead of matching them dynamically based on types, as Typer does.
It required the callback function to take exactly the 3 arguments `ctx`, `args` and `incomplete` in that exact order, instead of matching them dynamically based on types, as Typer does.

Since Click 8, this functionality has been replaced by [`shell_complete`](https://click.palletsprojects.com/en/8.1.x/api/#click.ParamType.shell_complete), which still depends on the exact order of arguments for the callback function.

Expand Down
Loading