Skip to content

Commit 71c8700

Browse files
gh-82151: Update and improve urlsplit docstring
Co-authored-by: idomic <michael.ido@gmail.com>
1 parent bcf98dd commit 71c8700

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

Doc/library/urllib.parse.rst

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,16 @@ or on combining URL components into a URL string.
6060
*missing_as_none* is true.
6161
Not defined component are represented an empty string (by default) or
6262
``None`` if *missing_as_none* is true.
63-
The components are not broken up
64-
into smaller parts (for example, the network location is a single string), and %
65-
escapes are not expanded. The delimiters as shown above are not part of the
66-
result, except for a leading slash in the *path* component, which is retained if
67-
present. For example:
63+
The delimiters as shown above are not part of the result, except for a
64+
leading slash in the *path* component, which is retained if present.
65+
66+
Additionally, the netloc property is broken down into these additional
67+
attributes added to the returned object: username, password, hostname, and
68+
port.
69+
70+
% escapes are not decoded.
71+
72+
For example:
6873

6974
.. doctest::
7075
:options: +NORMALIZE_WHITESPACE

0 commit comments

Comments
 (0)