lothc 0.2.3__cp315-cp315-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
lothc/__init__.py ADDED
@@ -0,0 +1,76 @@
1
+ from ._client import HTTPClient
2
+ from ._errors import (
3
+ HTTPConnectionError,
4
+ HTTPResponseError,
5
+ HTTPTimeoutError,
6
+ HTTPTransportError,
7
+ )
8
+ from ._headers import CaseInsensitiveDict
9
+ from ._oauth import (
10
+ OAuthProvider,
11
+ OAuthTokenError,
12
+ SyncOAuthProvider,
13
+ TokenRefreshRequestTyping,
14
+ TokenRequestTyping,
15
+ TokenResponseTyping,
16
+ )
17
+ from ._response import (
18
+ RequestInfo,
19
+ Response,
20
+ )
21
+ from ._settings import TlsVersion
22
+ from ._sse import SSEEvent
23
+ from ._sync_client import SyncHTTPClient
24
+ from ._types import (
25
+ AuthProvider,
26
+ Data,
27
+ File,
28
+ Form,
29
+ Headers,
30
+ JSONPayload,
31
+ Params,
32
+ SyncAuthProvider,
33
+ TypedHeaders,
34
+ )
35
+
36
+ __all__ = [
37
+ "AuthProvider",
38
+ "CaseInsensitiveDict",
39
+ "Data",
40
+ "File",
41
+ "Form",
42
+ "HTTPClient",
43
+ "HTTPConnectionError",
44
+ "HTTPResponseError",
45
+ "HTTPTimeoutError",
46
+ "HTTPTransportError",
47
+ "Headers",
48
+ "JSONPayload",
49
+ "OAuthProvider",
50
+ "OAuthTokenError",
51
+ "Params",
52
+ "RequestInfo",
53
+ "Response",
54
+ "SSEEvent",
55
+ "SyncAuthProvider",
56
+ "SyncHTTPClient",
57
+ "SyncOAuthProvider",
58
+ "TlsVersion",
59
+ "TokenRefreshRequestTyping",
60
+ "TokenRequestTyping",
61
+ "TokenResponseTyping",
62
+ "TypedHeaders",
63
+ ]
64
+
65
+
66
+ # Report every public class as `lothc.<Name>`, the path callers import it from, rather than the
67
+ # private module it lives in, so tracebacks and reprs read `lothc.HTTPResponseError` (httpx does
68
+ # the same). Pickle still finds each class, since `lothc` exports it.
69
+ def _report_as_public(namespace: dict[str, object], names: list[str], module: str) -> None:
70
+ for name in names:
71
+ exported = namespace[name]
72
+ if isinstance(exported, type):
73
+ exported.__module__ = module
74
+
75
+
76
+ _report_as_public(globals(), __all__, __name__)