-
Notifications
You must be signed in to change notification settings - Fork 876
process.extract() with scorer partial_ratio returns wrong results #216
Comments
Is there a reason the partial ratio result should be 100? And can you add a failing test case to our test suite to prove this? |
Yes. Since the shorter string is a substring of the longer string, partial_ratio should be 100. This is described in detail in github documentation as well as the blog
|
Do you mind adding the appropriate tests to test_fuzzywuzzy.py so that CI hits it and we can see the test fails? |
CI passes since it uses Python 3.5.3. This issue seems to happen in Python 3.6 or even 3.5.6 |
Mind filing a PR to use 3.5.6? |
I can confirm that this also happens in Python 3.7 |
in python 3.7, a shorter example that gives the same result:
|
Is there any solution for this issue? |
Correct answer to the following command should be 100.
Removal of any word from the string
nation hospitality honda water thane thane west
results in the correct answer of 100.This issue is reproducible in all installations (Irrespective of whether python-levenshtein is installed or not).
Versions:
The text was updated successfully, but these errors were encountered: