Skip to content

Commit b5befb1

Browse files
federico-e-martinezanselor
authored andcommitted
changes to make sphinx work and ordered the imports
1 parent 2a6fab4 commit b5befb1

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

cmd2/utils.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@
1212
import sys
1313
import threading
1414
import unicodedata
15-
from difflib import SequenceMatcher
15+
from difflib import (
16+
SequenceMatcher,
17+
)
1618
from enum import (
1719
Enum,
1820
)
@@ -1278,14 +1280,14 @@ def suggest_similar(
12781280
requested_command: str, options: Iterable[str], similarity_function_to_use: Optional[Callable[[str, str], float]] = None
12791281
) -> Optional[str]:
12801282
"""
1281-
Given a requested command and an iterable of possible options
1282-
returns the most similar (if any is similar)
1283+
Given a requested command and an iterable of possible options returns the most similar (if any is similar)
12831284
12841285
:param requested_command: The command entered by the user
1285-
:param options: The list of avaiable commands to search for the most similar
1286+
:param options: The list of available commands to search for the most similar
12861287
:param similarity_function_to_use: An optional callable to use to compare commands
1287-
:returns The most similar command or None if no one is similar
1288+
:return: The most similar command or None if no one is similar
12881289
"""
1290+
12891291
proposed_command = None
12901292
best_simil = MIN_SIMIL_TO_CONSIDER
12911293
requested_command_to_compare = requested_command.lower()

0 commit comments

Comments
 (0)