Skip to content

Commit aa4076f

Browse files
committed
Added versionchanged to get_error_hint.
1 parent 1674a27 commit aa4076f

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/click/core.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2356,8 +2356,13 @@ def get_usage_pieces(self, ctx: Context) -> list[str]:
23562356
return []
23572357

23582358
def get_error_hint(self, ctx: Context | None) -> str:
2359-
"""Get a stringified version of the param for use in error messages to
2359+
"""
2360+
Get a stringified version of the param for use in error messages to
23602361
indicate which param caused the error.
2362+
2363+
.. versionchanged:: 8.2
2364+
``ctx`` can be ``None``. This has technically always been the case,
2365+
but has been made explicit via typing.
23612366
"""
23622367
hint_list = self.opts or [self.human_readable_name]
23632368
return " / ".join(f"'{x}'" for x in hint_list)

0 commit comments

Comments
 (0)