Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 33.9k
Closed
Labels
type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Description
$ mkdir nonasciié $ TMPDIR=$PWD/nonasciié/ TEMP=$PWD/nonasciié/ ./python -m test test_urllib -v -m test_file_notexists (...) ERROR: test_file_notexists (test.test_urllib.urlopen_HttpTests.test_file_notexists) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/vstinner/python/main/Lib/urllib/parse.py", line 1004, in _to_bytes url = url.encode("ASCII").decode() ^^^^^^^^^^^^^^^^^^^ UnicodeEncodeError: 'ascii' codec can't encode character '\xe9' in position 52: ordinal not in range(128) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/vstinner/python/main/Lib/test/test_urllib.py", line 535, in test_file_notexists with urlopen(tmp_fileurl) as fobj: ^^^^^^^^^^^^^^^^^^^^ File "/home/vstinner/python/main/Lib/test/test_urllib.py", line 54, in urlopen return opener.open(url) ^^^^^^^^^^^^^^^^ File "/home/vstinner/python/main/Lib/urllib/request.py", line 1760, in open fullurl = unwrap(_to_bytes(fullurl)) ^^^^^^^^^^^^^^^^^^ File "/home/vstinner/python/main/Lib/urllib/parse.py", line 1006, in _to_bytes raise UnicodeError("URL " + repr(url) + ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ UnicodeError: URL 'file://localhost//home/vstinner/python/main/nonasciié/tmp3e6una03' contains non-ASCII characters Metadata
Metadata
Assignees
Labels
type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error