Closed
Description
Windows 3.13 CI is failing again due to upstream changes in CPython:
FAILED tests/unit/test_collector.py::test_ensure_quoted_url[file:///T:/path/with spaces/-file://///T:/path/with%20spaces] - AssertionError: assert 'file://///T:...ith%20spaces/' == 'file://///T:...with%20spaces'
- file://///T:/path/with%20spaces
+ file://///T:/path/with%20spaces/
? +
FAILED tests/unit/test_urls.py::test_path_to_url_win[\\\\unc\\as\\path-file:////unc/as/path] - AssertionError: assert 'file://unc/as/path' == 'file:////unc/as/path'
- file:////unc/as/path
? --
+ file://unc/as/path
Taking a look at the changelog for 3.13.1, these are all of the potential bugfixes implicated:
- urllib.request.url2pathname() mishandles empty authority sections (mostly) python/cpython#126766
- urllib.request.url2pathname() mishandles a UNC URI variant python/cpython#127078
- pathname2url() does not work if path starts with // python/cpython#127217
nturl2path.pathname2url()
doesn't handle forward slashes python/cpython#120423- urllib.request.pathname2url() and url2pathname() remove slashes on Windows python/cpython#126212
- urllib.request.pathname2url() mishandles UNC paths python/cpython#126205
cc @matthewhughes934 you've fixed a similar class of issues earlier. Would you be interested in taking a look at this?