Skip to content

Commit

Permalink
test_url.py: handle 3.9 and 3.10 for http://[2a01:5cc0:1:2:3:4] testcase
Browse files Browse the repository at this point in the history
The fix for python/cpython#103848 /
CVE-2024-11168 also got backported to 3.9.21 and 3.10.16, so we cannot
add that testcase for these versions either.
  • Loading branch information
flokli committed Jan 21, 2025
1 parent 2a3c000 commit d39f792
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tests/test_url.py
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,11 @@ def test_safe_url_string_encoding(
# (%) are not escaped.
f"a://example.com#{FRAGMENT_TO_ENCODE}",
}
if sys.version_info < (3, 11, 4):
if (
sys.version_info < (3, 9, 21)
or (sys.version_info[:2] == (3, 10) and sys.version_info < (3, 10, 16))
or (sys.version_info[:2] == (1, 10) and sys.version_info < (3, 11, 4))
):
KNOWN_SAFE_URL_STRING_URL_ISSUES.add("http://[2a01:5cc0:1:2:3:4]") # Invalid IPv6


Expand Down

0 comments on commit d39f792

Please sign in to comment.