Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions Doc/library/urllib.parse.rst
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,8 @@ or on combining URL components into a URL string.

The optional *encoding* and *errors* parameters specify how to decode
percent-encoded sequences into Unicode characters, as accepted by the
:meth:`bytes.decode` method.
:meth:`bytes.decode` method. See :func:`quote` for more about the
*encoding* and *errors* arguments.

The optional argument *max_num_fields* is the maximum number of fields to
read. If set, then throws a :exc:`ValueError` if there are more than
Expand Down Expand Up @@ -296,7 +297,8 @@ or on combining URL components into a URL string.

The optional *encoding* and *errors* parameters specify how to decode
percent-encoded sequences into Unicode characters, as accepted by the
:meth:`bytes.decode` method.
:meth:`bytes.decode` method. See :func:`quote` for more about the
*encoding* and *errors* arguments.

The optional argument *max_num_fields* is the maximum number of fields to
read. If set, then throws a :exc:`ValueError` if there are more than
Expand Down Expand Up @@ -652,7 +654,8 @@ task isn't already covered by the URL parsing functions above.
Although these parameters default to ``None`` in the function signature,
when processing :class:`str` inputs, *encoding* effectively defaults to ``'utf-8'``
and *errors* to ``'strict'``, meaning unsupported characters raise a
:class:`UnicodeEncodeError`.
:class:`UnicodeEncodeError`. See :ref:`standard-encodings` and
:ref:`error-handlers` for the values that *encoding* and *errors* can take.
*encoding* and *errors* must not be supplied if *string* is a
:class:`bytes`, or a :class:`TypeError` is raised.

Expand Down Expand Up @@ -692,7 +695,8 @@ task isn't already covered by the URL parsing functions above.

*encoding* defaults to ``'utf-8'``.
*errors* defaults to ``'replace'``, meaning invalid sequences are replaced
by a placeholder character.
by a placeholder character. See :func:`quote` for more about the
*encoding* and *errors* arguments.

Example: ``unquote('/El%20Ni%C3%B1o/')`` yields ``'/El Niño/'``.

Expand Down
Loading