]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-42037: Corrected request dependencies in CookieJar functions (GH-23112)
authormarkus-sus <73822103+markus-sus@users.noreply.github.com>
Mon, 1 Aug 2022 02:42:13 +0000 (04:42 +0200)
committerGitHub <noreply@github.com>
Mon, 1 Aug 2022 02:42:13 +0000 (10:42 +0800)
Doc/library/http.cookiejar.rst

index 51a8c53152b0193b11aef14f84830454ab9aefbf..53b3087a4b9997cdf769b06897f49016e6f2ac54 100644 (file)
@@ -160,11 +160,10 @@ contained :class:`Cookie` objects.
    respectively), the :mailheader:`Cookie2` header is also added when appropriate.
 
    The *request* object (usually a :class:`urllib.request.Request` instance)
-   must support the methods :meth:`get_full_url`, :meth:`get_host`,
-   :meth:`get_type`, :meth:`unverifiable`, :meth:`has_header`,
+   must support the methods :meth:`get_full_url`, :meth:`has_header`,
    :meth:`get_header`, :meth:`header_items`, :meth:`add_unredirected_header`
-   and :attr:`origin_req_host` attribute as documented by
-   :mod:`urllib.request`.
+   and the attributes :attr:`host`, :attr:`!type`, :attr:`unverifiable`
+   and :attr:`origin_req_host` as documented by :mod:`urllib.request`.
 
    .. versionchanged:: 3.3
 
@@ -186,11 +185,11 @@ contained :class:`Cookie` objects.
    method, which returns an :class:`email.message.Message` instance.
 
    The *request* object (usually a :class:`urllib.request.Request` instance)
-   must support the methods :meth:`get_full_url`, :meth:`get_host`,
-   :meth:`unverifiable`, and :attr:`origin_req_host` attribute, as documented
-   by :mod:`urllib.request`.  The request is used to set default values for
-   cookie-attributes as well as for checking that the cookie is allowed to be
-   set.
+   must support the method :meth:`get_full_url` and the attributes
+   :attr:`host`, :attr:`unverifiable` and :attr:`origin_req_host`,
+   as documented by :mod:`urllib.request`.  The request is used to set
+   default values for cookie-attributes as well as for checking that the
+   cookie is allowed to be set.
 
    .. versionchanged:: 3.3