Skip to content

Commit

Permalink
Keep clients in sync (#3120)
Browse files Browse the repository at this point in the history
Co-authored-by: Tom Christie <tom@tomchristie.com>
  • Loading branch information
karpetrosyan and tomchristie committed Feb 29, 2024
1 parent 7e10342 commit f3eb3c9
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions httpx/_client.py
Expand Up @@ -1054,7 +1054,7 @@ def get(
params: QueryParamTypes | None = None,
headers: HeaderTypes | None = None,
cookies: CookieTypes | None = None,
auth: AuthTypes | UseClientDefault = USE_CLIENT_DEFAULT,
auth: AuthTypes | UseClientDefault | None = USE_CLIENT_DEFAULT,
follow_redirects: bool | UseClientDefault = USE_CLIENT_DEFAULT,
timeout: TimeoutTypes | UseClientDefault = USE_CLIENT_DEFAULT,
extensions: RequestExtensions | None = None,
Expand Down Expand Up @@ -1391,8 +1391,7 @@ def __init__(
follow_redirects: bool = False,
limits: Limits = DEFAULT_LIMITS,
max_redirects: int = DEFAULT_MAX_REDIRECTS,
event_hooks: None
| (typing.Mapping[str, list[typing.Callable[..., typing.Any]]]) = None,
event_hooks: None | (typing.Mapping[str, list[EventHook]]) = None,
base_url: URLTypes = "",
transport: AsyncBaseTransport | None = None,
app: typing.Callable[..., typing.Any] | None = None,
Expand Down Expand Up @@ -1438,7 +1437,7 @@ def __init__(
)
warnings.warn(message, DeprecationWarning)

allow_env_proxies = trust_env and transport is None
allow_env_proxies = trust_env and app is None and transport is None
proxy_map = self._get_proxy_map(proxies or proxy, allow_env_proxies)

self._transport = self._init_transport(
Expand Down Expand Up @@ -1599,7 +1598,7 @@ async def stream(
params: QueryParamTypes | None = None,
headers: HeaderTypes | None = None,
cookies: CookieTypes | None = None,
auth: AuthTypes | UseClientDefault = USE_CLIENT_DEFAULT,
auth: AuthTypes | UseClientDefault | None = USE_CLIENT_DEFAULT,
follow_redirects: bool | UseClientDefault = USE_CLIENT_DEFAULT,
timeout: TimeoutTypes | UseClientDefault = USE_CLIENT_DEFAULT,
extensions: RequestExtensions | None = None,
Expand Down

0 comments on commit f3eb3c9

Please sign in to comment.