Skip to content

gh-156713: Use the filesystem encoding in nturl2path - #156717

Open
serhiy-storchaka wants to merge 1 commit into
python:mainfrom
serhiy-storchaka:gh-156713-nturl2path
Open

gh-156713: Use the filesystem encoding in nturl2path#156717
serhiy-storchaka wants to merge 1 commit into
python:mainfrom
serhiy-storchaka:gh-156713-nturl2path

Conversation

@serhiy-storchaka

Copy link
Copy Markdown
Member

urllib.request.pathname2url() and url2pathname() use the filesystem encoding and error handler since gh-85168, but the nturl2path module, which implemented them on Windows before 3.14, was left unchanged. Paths containing surrogate characters raised UnicodeEncodeError.

urllib.request.pathname2url() and url2pathname() use the filesystem encoding
and error handler since pythongh-85168, but nturl2path, which implements them on
Windows before 3.14, was left unchanged.  Paths containing surrogate
characters raised UnicodeEncodeError.
@serhiy-storchaka serhiy-storchaka added needs backport to 3.13 bugs and security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes labels Aug 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting core review needs backport to 3.13 bugs and security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant