|
3 | 3 | from __future__ import annotations |
4 | 4 |
|
5 | 5 | import os |
6 | | -from typing import Any, Union, Mapping |
| 6 | +from typing import Any, Mapping |
7 | 7 | from typing_extensions import Self, override |
8 | 8 |
|
9 | 9 | import httpx |
10 | 10 |
|
11 | 11 | from . import _exceptions |
12 | 12 | from ._qs import Querystring |
13 | 13 | from ._types import ( |
14 | | - NOT_GIVEN, |
15 | 14 | Omit, |
16 | 15 | Timeout, |
17 | 16 | NotGiven, |
18 | 17 | Transport, |
19 | 18 | ProxiesTypes, |
20 | 19 | RequestOptions, |
| 20 | + not_given, |
21 | 21 | ) |
22 | 22 | from ._utils import is_given, get_async_library |
23 | 23 | from ._version import __version__ |
@@ -48,7 +48,7 @@ def __init__( |
48 | 48 | *, |
49 | 49 | api_key: str | None = None, |
50 | 50 | base_url: str | httpx.URL | None = None, |
51 | | - timeout: Union[float, Timeout, None, NotGiven] = NOT_GIVEN, |
| 51 | + timeout: float | Timeout | None | NotGiven = not_given, |
52 | 52 | max_retries: int = DEFAULT_MAX_RETRIES, |
53 | 53 | default_headers: Mapping[str, str] | None = None, |
54 | 54 | default_query: Mapping[str, object] | None = None, |
@@ -125,9 +125,9 @@ def copy( |
125 | 125 | *, |
126 | 126 | api_key: str | None = None, |
127 | 127 | base_url: str | httpx.URL | None = None, |
128 | | - timeout: float | Timeout | None | NotGiven = NOT_GIVEN, |
| 128 | + timeout: float | Timeout | None | NotGiven = not_given, |
129 | 129 | http_client: httpx.Client | None = None, |
130 | | - max_retries: int | NotGiven = NOT_GIVEN, |
| 130 | + max_retries: int | NotGiven = not_given, |
131 | 131 | default_headers: Mapping[str, str] | None = None, |
132 | 132 | set_default_headers: Mapping[str, str] | None = None, |
133 | 133 | default_query: Mapping[str, object] | None = None, |
@@ -220,7 +220,7 @@ def __init__( |
220 | 220 | *, |
221 | 221 | api_key: str | None = None, |
222 | 222 | base_url: str | httpx.URL | None = None, |
223 | | - timeout: Union[float, Timeout, None, NotGiven] = NOT_GIVEN, |
| 223 | + timeout: float | Timeout | None | NotGiven = not_given, |
224 | 224 | max_retries: int = DEFAULT_MAX_RETRIES, |
225 | 225 | default_headers: Mapping[str, str] | None = None, |
226 | 226 | default_query: Mapping[str, object] | None = None, |
@@ -297,9 +297,9 @@ def copy( |
297 | 297 | *, |
298 | 298 | api_key: str | None = None, |
299 | 299 | base_url: str | httpx.URL | None = None, |
300 | | - timeout: float | Timeout | None | NotGiven = NOT_GIVEN, |
| 300 | + timeout: float | Timeout | None | NotGiven = not_given, |
301 | 301 | http_client: httpx.AsyncClient | None = None, |
302 | | - max_retries: int | NotGiven = NOT_GIVEN, |
| 302 | + max_retries: int | NotGiven = not_given, |
303 | 303 | default_headers: Mapping[str, str] | None = None, |
304 | 304 | set_default_headers: Mapping[str, str] | None = None, |
305 | 305 | default_query: Mapping[str, object] | None = None, |
|
0 commit comments