Skip to content

Commit

Permalink
Correct requests cookies argument (#12654)
Browse files Browse the repository at this point in the history
  • Loading branch information
max-muoto authored Sep 13, 2024
1 parent 99f6238 commit df30049
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions stubs/requests/requests/api.pyi
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
from _typeshed import Incomplete
from collections.abc import Mapping
from http.cookiejar import CookieJar
from typing_extensions import TypeAlias

from .models import Response
from .sessions import RequestsCookieJar, _Auth, _Cert, _Data, _Files, _HooksInput, _Params, _TextMapping, _Timeout, _Verify
from .sessions import _Auth, _Cert, _Data, _Files, _HooksInput, _Params, _TextMapping, _Timeout, _Verify

_HeadersMapping: TypeAlias = Mapping[str, str | bytes | None]

Expand All @@ -14,7 +15,7 @@ def request(
params: _Params | None = ...,
data: _Data | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -32,7 +33,7 @@ def get(
*,
data: _Data | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -50,7 +51,7 @@ def options(
params: _Params | None = ...,
data: _Data | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -68,7 +69,7 @@ def head(
params: _Params | None = ...,
data: _Data | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -87,7 +88,7 @@ def post(
*,
params: _Params | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -104,7 +105,7 @@ def put(
*,
params: _Params | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -122,7 +123,7 @@ def patch(
*,
params: _Params | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand All @@ -140,7 +141,7 @@ def delete(
params: _Params | None = ...,
data: _Data | None = ...,
headers: _HeadersMapping | None = ...,
cookies: RequestsCookieJar | _TextMapping | None = ...,
cookies: CookieJar | _TextMapping | None = ...,
files: _Files | None = ...,
auth: _Auth | None = ...,
timeout: _Timeout | None = ...,
Expand Down

0 comments on commit df30049

Please sign in to comment.