From 314a18ecff56b04ef21b383133def10c7c2ec53c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Behmo?= Date: Thu, 14 Apr 2022 19:15:14 +0200 Subject: [PATCH] fix: get_command argument type error A previous fix partially resolve an issue with incorrect command type passed to list_commands, but the same fix should have been applied to get_command as well. Close #70 (again). --- sphinx_click/ext.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sphinx_click/ext.py b/sphinx_click/ext.py index 6302f78..b516f05 100644 --- a/sphinx_click/ext.py +++ b/sphinx_click/ext.py @@ -249,7 +249,7 @@ def _format_epilog(ctx: click.Context) -> ty.Generator[str, None, None]: def _get_lazyload_commands(ctx: click.Context) -> ty.Dict[str, click.Command]: commands = {} for command in ctx.command.list_commands(ctx): - commands[command] = ctx.command.get_command(ctx.command, command) + commands[command] = ctx.command.get_command(ctx, command) return commands