Skip to content
This repository has been archived by the owner on Aug 26, 2024. It is now read-only.

Clarify extractOne return type #312

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions fuzzywuzzy/process.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,10 @@ def extractOne(query, choices, processor=default_processor, scorer=default_score
Returns:
A tuple containing a single match and its score, if a match
was found that was above score_cutoff. Otherwise, returns None.

If a list is used for choices, then the result will be 2-tuples.
If a dictionary is used, then the result will be 3-tuples containing
the key for each match.
"""
best_list = extractWithoutOrder(query, choices, processor, scorer, score_cutoff)
try:
Expand Down