Skip to content

Commit a5570cc

Browse files
committed
Updated comment.
1 parent 74a2889 commit a5570cc

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

cmd2/completion.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,14 +49,14 @@ class CompletionItem:
4949
# control sequences (like ^J or ^I) in the completion menu.
5050
_CONTROL_WHITESPACE_RE = re.compile(r"\r\n|[\n\r\t\f\v]")
5151

52-
# The core object this completion represents (e.g., str, int, Path).
53-
# This serves as the default source for the completion string and is used
54-
# to support object-based validation when used in argparse choices.
52+
# The underlying object this completion represents (e.g., str, int, Path).
53+
# This serves as the default source for 'text' and is used to support
54+
# object-based validation when this item is used as an argparse choice.
5555
value: Any = field(kw_only=False)
5656

57-
# The actual completion string. If not provided, defaults to str(value).
58-
# This can be used to provide a human-friendly alias for complex objects in
59-
# an argparse choices list (requires a matching 'type' converter for validation).
57+
# The actual completion string. Defaults to str(value). This should only be
58+
# set manually if this item is used as an argparse choice and you want the
59+
# choice string to differ from str(value).
6060
text: str = _UNSET_STR
6161

6262
# Optional string for displaying the completion differently in the completion menu.

0 commit comments

Comments
 (0)