Correct Glossary key function example to use str.casefold instead of str.lower (#140316)

This commit is contained in:
Cameron Beck 2025-12-16 06:44:12 -05:00 committed by GitHub
parent 2450be607c
commit 190aa9fe7e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -813,7 +813,7 @@ Glossary
:func:`itertools.groupby`.
There are several ways to create a key function. For example. the
:meth:`str.lower` method can serve as a key function for case insensitive
:meth:`str.casefold` method can serve as a key function for case insensitive
sorts. Alternatively, a key function can be built from a
:keyword:`lambda` expression such as ``lambda r: (r[0], r[2])``. Also,
:func:`operator.attrgetter`, :func:`operator.itemgetter`, and