Message372009
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'] |
|
Date |
User |
Action |
Args |
2020-06-21 17:46:22 | remi.lapeyre | set | recipients:
+ remi.lapeyre, lemburg, tim.peters, rhettinger, python-dev, brian.gallagher |
2020-06-21 17:46:22 | remi.lapeyre | set | messageid: <1592761582.37.0.498274329082.issue39891@roundup.psfhosted.org> |
2020-06-21 17:46:22 | remi.lapeyre | link | issue39891 messages |
2020-06-21 17:46:22 | remi.lapeyre | create | |
|