Issue #20059: urllib.parse raises ValueError on all invalid ports.
Patch by Martin Panter.
diff --git a/Doc/whatsnew/3.6.rst b/Doc/whatsnew/3.6.rst
index 4e686ad..e2aa1e2 100644
--- a/Doc/whatsnew/3.6.rst
+++ b/Doc/whatsnew/3.6.rst
@@ -162,7 +162,10 @@
Changes in the Python API
-------------------------
-* None yet.
+* Reading the :attr:`~urllib.parse.SplitResult.port` attribute of
+ :func:`urllib.parse.urlsplit` and :func:`~urllib.parse.urlparse` results
+ now raises :exc:`ValueError` for out-of-range values, rather than
+ returning :const:`None`. See :issue:`20059`.
Changes in the C API