Skip to content
Prev Previous commit
apply victor's comment
  • Loading branch information
shihai1991 committed Oct 13, 2020
commit 4ecb8a1bb1f5e973e8d3eaeb0685d849d4023555
2 changes: 1 addition & 1 deletion Doc/whatsnew/3.10.rst
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ support is provided by the underlying ncurses library.

encodings
---------
:func:`encodings.normalize_encoding` now ignores non-ASCII letters.
:func:`encodings.normalize_encoding` now ignores non-ASCII characters.
(Contributed by Hai Shi in :issue:`39337`.)

glob
Expand Down
2 changes: 1 addition & 1 deletion Lib/test/test_codecs.py
Original file line number Diff line number Diff line change
Expand Up @@ -3440,7 +3440,7 @@ def search_function(encoding):
self.assertEqual(NOT_FOUND, codecs.lookup('a\xe9\u20ac-8'))

def test_encodings_normalize_encoding(self):
Comment thread
shihai1991 marked this conversation as resolved.
# encodings.normalize_encoding() ignores non-ASCII letters.
# encodings.normalize_encoding() ignores non-ASCII characters.
normalize = encodings.normalize_encoding
self.assertEqual(normalize('utf_8'), 'utf_8')
self.assertEqual(normalize('utf\xE9\u20AC\U0010ffff-8'), 'utf_8')
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
:func:`encodings.normalize_encoding` now ignores non-ASCII letters.
:func:`encodings.normalize_encoding` now ignores non-ASCII characters.