This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author remi.lapeyre
Recipients brian.gallagher, lemburg, python-dev, remi.lapeyre, rhettinger, tim.peters
Date 2020-06-21.17:46:22
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1592761582.37.0.498274329082.issue39891@roundup.psfhosted.org>
In-reply-to
Content
I fell like it's a bit weird to have a new function just for ignoring case, will a new function be required for every possible normalization like removing accents. One possible make the API handle those use cases would be to have a keyword-argument for this:


>>> difflib.get_close_matches('apple', ['APPLE'], normalization=str.lower)
['APPLE']

Then it could work with other normalization too without requiring a new function every time:

>>> difflib.get_close_matches('Remi', ['Rémi'], normalization=remove_a ccents)
['Rémi']
History
Date User Action Args
2020-06-21 17:46:22remi.lapeyresetrecipients: + remi.lapeyre, lemburg, tim.peters, rhettinger, python-dev, brian.gallagher
2020-06-21 17:46:22remi.lapeyresetmessageid: <1592761582.37.0.498274329082.issue39891@roundup.psfhosted.org>
2020-06-21 17:46:22remi.lapeyrelinkissue39891 messages
2020-06-21 17:46:22remi.lapeyrecreate