]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-42037: Corrected request dependencies in CookieJar functions (GH-23112) (GH-95515)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Fri, 5 Aug 2022 08:20:29 +0000 (01:20 -0700)
committerGitHub <noreply@github.com>
Fri, 5 Aug 2022 08:20:29 +0000 (10:20 +0200)
(cherry picked from commit d29e279de38e7bc3b7deda573ba23d65831d9351)

Co-authored-by: markus-sus <73822103+markus-sus@users.noreply.github.com>
Doc/library/http.cookiejar.rst

index 3d59665be4f2540e281f3441cc507d1a821519f7..ba2fa018499c62bcc71ca919798ddfa18b317076 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