smithy-http 0.6.0__tar.gz → 0.8.0__tar.gz

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.
Files changed (63) hide show
  1. smithy_http-0.8.0/.changes/0.7.0.json +80 -0
  2. smithy_http-0.8.0/.changes/0.8.0.json +92 -0
  3. {smithy_http-0.6.0 → smithy_http-0.8.0}/.gitignore +3 -0
  4. smithy_http-0.8.0/CHANGELOG.md +162 -0
  5. {smithy_http-0.6.0 → smithy_http-0.8.0}/PKG-INFO +18 -8
  6. {smithy_http-0.6.0 → smithy_http-0.8.0}/README.md +7 -4
  7. {smithy_http-0.6.0 → smithy_http-0.8.0}/pyproject.toml +13 -3
  8. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/__init__.py +102 -46
  9. smithy_http-0.8.0/src/smithy_http/aio/__init__.py +5 -0
  10. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/aio/aiohttp.py +87 -57
  11. {smithy_http-0.6.0/src/smithy_http/interceptors → smithy_http-0.8.0/src/smithy_http/aio/auth}/__init__.py +1 -0
  12. smithy_http-0.8.0/src/smithy_http/aio/auth/apikey.py +57 -0
  13. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/aio/crt.py +106 -82
  14. {smithy_http-0.6.0/src/smithy_http/aio/auth → smithy_http-0.8.0/src/smithy_http/aio/identity}/__init__.py +1 -0
  15. smithy_http-0.8.0/src/smithy_http/aio/identity/apikey.py +25 -0
  16. smithy_http-0.8.0/src/smithy_http/aio/interfaces/__init__.py +51 -0
  17. smithy_http-0.8.0/src/smithy_http/aio/protocols.py +334 -0
  18. smithy_http-0.8.0/src/smithy_http/aio/restjson.py +24 -0
  19. smithy_http-0.8.0/src/smithy_http/aio/testing.py +43 -0
  20. smithy_http-0.8.0/src/smithy_http/auth/__init__.py +2 -0
  21. {smithy_http-0.6.0/src/smithy_http/aio → smithy_http-0.8.0/src/smithy_http}/auth/apikey.py +34 -31
  22. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/bindings.py +3 -9
  23. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/deserializers.py +68 -67
  24. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/endpoints.py +5 -1
  25. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/exceptions.py +2 -0
  26. smithy_http-0.8.0/src/smithy_http/identity/__init__.py +23 -0
  27. smithy_http-0.8.0/src/smithy_http/identity/apikey.py +25 -0
  28. {smithy_http-0.6.0/src/smithy_http/aio/identity → smithy_http-0.8.0/src/smithy_http/interceptors}/__init__.py +1 -0
  29. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/interceptors/user_agent.py +4 -1
  30. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/interfaces/__init__.py +113 -6
  31. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/plugins/__init__.py +3 -0
  32. smithy_http-0.8.0/src/smithy_http/protocols.py +940 -0
  33. smithy_http-0.8.0/src/smithy_http/restjson.py +89 -0
  34. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/schema_extensions.py +17 -24
  35. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/serializers.py +228 -224
  36. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/testing/mockhttp.py +62 -55
  37. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/testing/utils.py +3 -2
  38. smithy_http-0.8.0/src/smithy_http/urllib3.py +266 -0
  39. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/user_agent.py +10 -1
  40. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/utils.py +21 -19
  41. smithy_http-0.6.0/CHANGELOG.md +0 -97
  42. smithy_http-0.6.0/src/smithy_http/aio/__init__.py +0 -53
  43. smithy_http-0.6.0/src/smithy_http/aio/identity/apikey.py +0 -38
  44. smithy_http-0.6.0/src/smithy_http/aio/interfaces/__init__.py +0 -110
  45. smithy_http-0.6.0/src/smithy_http/aio/protocols.py +0 -518
  46. smithy_http-0.6.0/src/smithy_http/aio/restjson.py +0 -60
  47. smithy_http-0.6.0/src/smithy_http/restjson.py +0 -29
  48. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.0.1.json +0 -0
  49. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.1.0.json +0 -0
  50. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.2.0.json +0 -0
  51. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.2.1.json +0 -0
  52. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.3.0.json +0 -0
  53. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.3.1.json +0 -0
  54. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.4.0.json +0 -0
  55. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.4.1.json +0 -0
  56. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.4.2.json +0 -0
  57. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.4.3.json +0 -0
  58. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.4.4.json +0 -0
  59. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.5.0.json +0 -0
  60. {smithy_http-0.6.0 → smithy_http-0.8.0}/.changes/0.6.0.json +0 -0
  61. {smithy_http-0.6.0 → smithy_http-0.8.0}/NOTICE +0 -0
  62. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/py.typed +0 -0
  63. {smithy_http-0.6.0 → smithy_http-0.8.0}/src/smithy_http/testing/__init__.py +0 -0
@@ -0,0 +1,80 @@
1
+ {
2
+ "changes": [
3
+ {
4
+ "type": "breaking",
5
+ "description": "Replaced the async protocols with event stream mixins composed onto the sync protocols. `AsyncHttpClientProtocol`, `AsyncHttpBindingClientProtocol` and `AsyncRpcClientProtocol` are removed; use `AsyncHttpEventStreamMixin` or `AsyncRpcEventStreamMixin` with a protocol from `smithy_http.protocols`. `AsyncRpcV2CborClientProtocol` is kept as such a composition."
6
+ },
7
+ {
8
+ "type": "breaking",
9
+ "description": "Moved `HTTPRequest` and `HTTPResponse` to `smithy_http`, and their protocols and `HTTPErrorIdentifier` to `smithy_http.interfaces`. Removed `consume_body_async`."
10
+ },
11
+ {
12
+ "type": "breaking",
13
+ "description": "Removed `AsyncAPIKeySigner`; `AsyncAPIKeyAuthScheme` returns the sync `APIKeySigner`. Renamed `smithy_http.aio.restjson.parse_rest_json_error_info` to `parse_rest_json_error_info_async`."
14
+ },
15
+ {
16
+ "type": "breaking",
17
+ "description": "Serialized request bodies are now synchronous for both sync and async clients. `HTTPBindingSerializer`'s `async_body` parameter is replaced by `event_stream_body`, and `RawPayloadDeserializer` returns streaming payloads as the transport provides them."
18
+ },
19
+ {
20
+ "type": "breaking",
21
+ "description": "Moved async implementations to `smithy_http.aio` and added the `Async` prefix to their names, for example `AsyncHTTPClient`, `AsyncHttpClientProtocol`, `AsyncHttpBindingClientProtocol`, `AsyncRpcV2CborClientProtocol` and `AsyncAPIKeyAuthScheme`. The unprefixed names are reserved for sync implementations. Update imports to the `aio` paths."
22
+ },
23
+ {
24
+ "type": "breaking",
25
+ "description": "Declared explicit `__all__` exports on all public modules. Names that were previously importable only incidentally (via `from module import *` or as un-annotated module attributes) are no longer part of the public API; import public symbols by name from their documented module."
26
+ },
27
+ {
28
+ "type": "breaking",
29
+ "description": "`smithy_http.testing.MockHTTPClient` is now synchronous. Async clients use `smithy_http.aio.testing.AsyncMockHTTPClient`."
30
+ },
31
+ {
32
+ "type": "breaking",
33
+ "description": "Renamed `AWSCRTHTTPResponse` to `AsyncAWSCRTHTTPResponse`, and `smithy_http.aio.auth.apikey.APIKeyResolverConfig` to `AsyncAPIKeyResolverConfig`."
34
+ },
35
+ {
36
+ "type": "feature",
37
+ "description": "Added synchronous HTTP support: `smithy_http.urllib3.Urllib3HTTPClient`, the sync protocols in `smithy_http.protocols`, `smithy_http.restjson.parse_rest_json_error_info` and `smithy_http.identity.apikey.APIKeyIdentityResolver`."
38
+ },
39
+ {
40
+ "type": "feature",
41
+ "description": "Added `connect_timeout` and `read_timeout` to `Urllib3HTTPClientConfig`, both defaulting to 60 seconds, so sync requests no longer wait indefinitely. A request's `HTTPRequestConfiguration.read_timeout` takes precedence."
42
+ },
43
+ {
44
+ "type": "feature",
45
+ "description": "Added `max_pool_connections` to `Urllib3HTTPClientConfig`, the connections kept for reuse per host, defaulting to 10 instead of urllib3's 1."
46
+ },
47
+ {
48
+ "type": "feature",
49
+ "description": "Added a RpcClientProtocol base class and client-side event stream support for the rpcv2Cbor protocol."
50
+ },
51
+ {
52
+ "type": "enhancement",
53
+ "description": "AWSCRTHTTPClient now negotiates HTTP/2 per request for operations that require it (event streams), advertising only HTTP/2 in ALPN and pooling those connections separately from HTTP/1.1 ones, so a single client serves both HTTP/1.1 operations and HTTP/2 event streams without configuration. The client-wide force_http_2 config remains as an override."
54
+ },
55
+ {
56
+ "type": "enhancement",
57
+ "description": "Added a trust_store_path option to AWSCRTHTTPClientConfig for overriding the TLS trust store with a custom CA bundle."
58
+ },
59
+ {
60
+ "type": "enhancement",
61
+ "description": "Added support for Python 3.15."
62
+ },
63
+ {
64
+ "type": "bugfix",
65
+ "description": "Fixed HTTP serializers sending seekable streaming payloads, such as files, without a Content-Length and sending a modeled Content-Length twice."
66
+ },
67
+ {
68
+ "type": "bugfix",
69
+ "description": "Fixed API key auth setting the request path to the URI password."
70
+ },
71
+ {
72
+ "type": "bugfix",
73
+ "description": "`APIKeyIdentity` no longer includes `api_key` in its repr, which keeps it out of debug logs."
74
+ },
75
+ {
76
+ "type": "dependency",
77
+ "description": "Bump `smithy-cbor` from `~=0.1.0` to `~=0.2.0`."
78
+ }
79
+ ]
80
+ }
@@ -0,0 +1,92 @@
1
+ {
2
+ "changes": [
3
+ {
4
+ "type": "breaking",
5
+ "description": "Removed the eventloop parameter from AWSCRTHTTPClient."
6
+ },
7
+ {
8
+ "type": "breaking",
9
+ "description": "Removed `HostPrefixSerializer` and `Binding.HOST`. `@hostLabel` no longer changes where a member is serialized and smithy-core now applies host prefixes."
10
+ },
11
+ {
12
+ "type": "feature",
13
+ "description": "Added support for the `aws.protocols#awsQueryCompatible` trait to `RpcV2CborClientProtocol` and `RpcV2JsonClientProtocol`."
14
+ },
15
+ {
16
+ "type": "feature",
17
+ "description": "Added `RpcV2JsonClientProtocol` and `AsyncRpcV2JsonClientProtocol`, implementations of the `smithy.protocols#rpcv2Json` protocol, and a `json` extra that installs `smithy-json`."
18
+ },
19
+ {
20
+ "type": "enhancement",
21
+ "description": "Documented HTTPQueryMapValueSerializer."
22
+ },
23
+ {
24
+ "type": "enhancement",
25
+ "description": "Completed type annotations and __all__ declarations for the public API."
26
+ },
27
+ {
28
+ "type": "enhancement",
29
+ "description": "Allow MockHTTPClient and AsyncMockHTTPClient responses to have stream bodies."
30
+ },
31
+ {
32
+ "type": "enhancement",
33
+ "description": "Imported symbols from their defining modules."
34
+ },
35
+ {
36
+ "type": "bugfix",
37
+ "description": "Iterating a `Urllib3HTTPClient` response body now yields 64 KiB chunks instead of 1 KiB ones."
38
+ },
39
+ {
40
+ "type": "bugfix",
41
+ "description": "RPC v2 protocols (including `RpcV2CborClientProtocol` and `AsyncRpcV2CborClientProtocol`) now treat a response whose `Smithy-Protocol` header does not match the request as malformed, raising a `CallError` based solely on the HTTP status code without interpreting the body."
42
+ },
43
+ {
44
+ "type": "bugfix",
45
+ "description": "Declared smithy-aws-event-stream as the eventstream extra, bounded yarl, and raised MissingDependencyError when the aiohttp extra is not installed."
46
+ },
47
+ {
48
+ "type": "bugfix",
49
+ "description": "`Urllib3HTTPClient` now streams request bodies that are readers with a known length or chunked transfer encoding, such as an open file, instead of reading the whole body into memory first. Uploads are sent in 128 KiB blocks."
50
+ },
51
+ {
52
+ "type": "bugfix",
53
+ "description": "Derived the CRT timeout error from SmithyHTTPError."
54
+ },
55
+ {
56
+ "type": "bugfix",
57
+ "description": "`Field.as_string()` now joins values with its `delimiter` argument, a bare comma by default, instead of always using a comma and a space. The `Field` interface now declares the `delimiter` parameter. `AIOHTTPClient` and `Urllib3HTTPClient` no longer send trailer fields as headers, matching `AWSCRTHTTPClient`."
58
+ },
59
+ {
60
+ "type": "bugfix",
61
+ "description": "`AIOHTTPClient` now reads request bodies that are readers, such as open files, in 128 KiB chunks instead of 1 KiB ones, which made uploads about 25 times faster on fast connections. An async iterable body is now passed to aiohttp unchanged, so each item is sent as soon as it's produced."
62
+ },
63
+ {
64
+ "type": "bugfix",
65
+ "description": "`AIOHTTPClient` now sends requests that set `Transfer-Encoding: chunked` using aiohttp's chunked uploads. Previously aiohttp rejected the header with a `ValueError`."
66
+ },
67
+ {
68
+ "type": "bugfix",
69
+ "description": "RPC v2 protocols now raise a `CallError` instead of an unrelated exception for error responses whose body cannot be decoded or whose `__type` is not an absolute shape ID, and resolve `__type` values with a `:`-delimited suffix to the modeled error."
70
+ },
71
+ {
72
+ "type": "bugfix",
73
+ "description": "The urllib3 HTTP client now streams response bodies instead of reading each one into memory. A streaming output, such as an S3 `GetObject` body, holds its connection until it is read to the end or closed, so use it in a `with` block to release the connection early."
74
+ },
75
+ {
76
+ "type": "dependency",
77
+ "description": "Bump `smithy-core` from `~=0.10.0` to `~=0.11.0`."
78
+ },
79
+ {
80
+ "type": "dependency",
81
+ "description": "Bump `smithy-cbor` from `~=0.2.0` to `~=0.3.0`."
82
+ },
83
+ {
84
+ "type": "dependency",
85
+ "description": "Bump `smithy-json` from `~=0.4.0` to `~=0.5.0`."
86
+ },
87
+ {
88
+ "type": "dependency",
89
+ "description": "Bump `smithy-aws-event-stream` from `~=0.4.0` to `~=0.5.0`."
90
+ }
91
+ ]
92
+ }
@@ -34,3 +34,6 @@ htmlcov
34
34
  *.egg-info
35
35
  dist
36
36
  .venv
37
+
38
+ # make gen
39
+ /workspace/
@@ -0,0 +1,162 @@
1
+ # Changelog
2
+
3
+ ## v0.8.0
4
+
5
+ ### Breaking Changes
6
+ * Removed the eventloop parameter from AWSCRTHTTPClient.
7
+ * Removed `HostPrefixSerializer` and `Binding.HOST`. `@hostLabel` no longer changes where a member is serialized and smithy-core now applies host prefixes.
8
+
9
+ ### Features
10
+ * Added support for the `aws.protocols#awsQueryCompatible` trait to `RpcV2CborClientProtocol` and `RpcV2JsonClientProtocol`.
11
+ * Added `RpcV2JsonClientProtocol` and `AsyncRpcV2JsonClientProtocol`, implementations of the `smithy.protocols#rpcv2Json` protocol, and a `json` extra that installs `smithy-json`.
12
+
13
+ ### Enhancements
14
+ * Documented HTTPQueryMapValueSerializer.
15
+ * Completed type annotations and __all__ declarations for the public API.
16
+ * Allow MockHTTPClient and AsyncMockHTTPClient responses to have stream bodies.
17
+ * Imported symbols from their defining modules.
18
+
19
+ ### Bug fixes
20
+ * Iterating a `Urllib3HTTPClient` response body now yields 64 KiB chunks instead of 1 KiB ones.
21
+ * RPC v2 protocols (including `RpcV2CborClientProtocol` and `AsyncRpcV2CborClientProtocol`) now treat a response whose `Smithy-Protocol` header does not match the request as malformed, raising a `CallError` based solely on the HTTP status code without interpreting the body.
22
+ * Declared smithy-aws-event-stream as the eventstream extra, bounded yarl, and raised MissingDependencyError when the aiohttp extra is not installed.
23
+ * `Urllib3HTTPClient` now streams request bodies that are readers with a known length or chunked transfer encoding, such as an open file, instead of reading the whole body into memory first. Uploads are sent in 128 KiB blocks.
24
+ * Derived the CRT timeout error from SmithyHTTPError.
25
+ * `Field.as_string()` now joins values with its `delimiter` argument, a bare comma by default, instead of always using a comma and a space. The `Field` interface now declares the `delimiter` parameter. `AIOHTTPClient` and `Urllib3HTTPClient` no longer send trailer fields as headers, matching `AWSCRTHTTPClient`.
26
+ * `AIOHTTPClient` now reads request bodies that are readers, such as open files, in 128 KiB chunks instead of 1 KiB ones, which made uploads about 25 times faster on fast connections. An async iterable body is now passed to aiohttp unchanged, so each item is sent as soon as it's produced.
27
+ * `AIOHTTPClient` now sends requests that set `Transfer-Encoding: chunked` using aiohttp's chunked uploads. Previously aiohttp rejected the header with a `ValueError`.
28
+ * RPC v2 protocols now raise a `CallError` instead of an unrelated exception for error responses whose body cannot be decoded or whose `__type` is not an absolute shape ID, and resolve `__type` values with a `:`-delimited suffix to the modeled error.
29
+ * The urllib3 HTTP client now streams response bodies instead of reading each one into memory. A streaming output, such as an S3 `GetObject` body, holds its connection until it is read to the end or closed, so use it in a `with` block to release the connection early.
30
+
31
+ ### Dependencies
32
+ * Bump `smithy-core` from `~=0.10.0` to `~=0.11.0`.
33
+ * Bump `smithy-cbor` from `~=0.2.0` to `~=0.3.0`.
34
+ * Bump `smithy-json` from `~=0.4.0` to `~=0.5.0`.
35
+ * Bump `smithy-aws-event-stream` from `~=0.4.0` to `~=0.5.0`.
36
+
37
+ ## v0.7.0
38
+
39
+ ### Breaking Changes
40
+ * Replaced the async protocols with event stream mixins composed onto the sync protocols. `AsyncHttpClientProtocol`, `AsyncHttpBindingClientProtocol` and `AsyncRpcClientProtocol` are removed; use `AsyncHttpEventStreamMixin` or `AsyncRpcEventStreamMixin` with a protocol from `smithy_http.protocols`. `AsyncRpcV2CborClientProtocol` is kept as such a composition.
41
+ * Moved `HTTPRequest` and `HTTPResponse` to `smithy_http`, and their protocols and `HTTPErrorIdentifier` to `smithy_http.interfaces`. Removed `consume_body_async`.
42
+ * Removed `AsyncAPIKeySigner`; `AsyncAPIKeyAuthScheme` returns the sync `APIKeySigner`. Renamed `smithy_http.aio.restjson.parse_rest_json_error_info` to `parse_rest_json_error_info_async`.
43
+ * Serialized request bodies are now synchronous for both sync and async clients. `HTTPBindingSerializer`'s `async_body` parameter is replaced by `event_stream_body`, and `RawPayloadDeserializer` returns streaming payloads as the transport provides them.
44
+ * Moved async implementations to `smithy_http.aio` and added the `Async` prefix to their names, for example `AsyncHTTPClient`, `AsyncHttpClientProtocol`, `AsyncHttpBindingClientProtocol`, `AsyncRpcV2CborClientProtocol` and `AsyncAPIKeyAuthScheme`. The unprefixed names are reserved for sync implementations. Update imports to the `aio` paths.
45
+ * Declared explicit `__all__` exports on all public modules. Names that were previously importable only incidentally (via `from module import *` or as un-annotated module attributes) are no longer part of the public API; import public symbols by name from their documented module.
46
+ * `smithy_http.testing.MockHTTPClient` is now synchronous. Async clients use `smithy_http.aio.testing.AsyncMockHTTPClient`.
47
+ * Renamed `AWSCRTHTTPResponse` to `AsyncAWSCRTHTTPResponse`, and `smithy_http.aio.auth.apikey.APIKeyResolverConfig` to `AsyncAPIKeyResolverConfig`.
48
+
49
+ ### Features
50
+ * Added synchronous HTTP support: `smithy_http.urllib3.Urllib3HTTPClient`, the sync protocols in `smithy_http.protocols`, `smithy_http.restjson.parse_rest_json_error_info` and `smithy_http.identity.apikey.APIKeyIdentityResolver`.
51
+ * Added `connect_timeout` and `read_timeout` to `Urllib3HTTPClientConfig`, both defaulting to 60 seconds, so sync requests no longer wait indefinitely. A request's `HTTPRequestConfiguration.read_timeout` takes precedence.
52
+ * Added `max_pool_connections` to `Urllib3HTTPClientConfig`, the connections kept for reuse per host, defaulting to 10 instead of urllib3's 1.
53
+ * Added a RpcClientProtocol base class and client-side event stream support for the rpcv2Cbor protocol.
54
+
55
+ ### Enhancements
56
+ * AWSCRTHTTPClient now negotiates HTTP/2 per request for operations that require it (event streams), advertising only HTTP/2 in ALPN and pooling those connections separately from HTTP/1.1 ones, so a single client serves both HTTP/1.1 operations and HTTP/2 event streams without configuration. The client-wide force_http_2 config remains as an override.
57
+ * Added a trust_store_path option to AWSCRTHTTPClientConfig for overriding the TLS trust store with a custom CA bundle.
58
+ * Added support for Python 3.15.
59
+
60
+ ### Bug fixes
61
+ * Fixed HTTP serializers sending seekable streaming payloads, such as files, without a Content-Length and sending a modeled Content-Length twice.
62
+ * Fixed API key auth setting the request path to the URI password.
63
+ * `APIKeyIdentity` no longer includes `api_key` in its repr, which keeps it out of debug logs.
64
+
65
+ ### Dependencies
66
+ * Bump `smithy-cbor` from `~=0.1.0` to `~=0.2.0`.
67
+
68
+ ## v0.6.0
69
+
70
+ ### Features
71
+ * `HttpClientProtocol` implements `extract_response_metadata()`, reporting the HTTP status code.
72
+ * Added a naive `RpcV2CborClientProtocol` for the `smithy.protocols#rpcv2Cbor` protocol (optional `cbor` extra).
73
+ * Added schema-cached HTTP binding plans for members, operations, payloads, and request and response dispatch.
74
+
75
+ ### Dependencies
76
+ * Bump `smithy-cbor` from `~=0.0.0` to `~=0.1.0`.
77
+
78
+ ## v0.5.0
79
+
80
+ ### Features
81
+ * Added deterministic connection-pool cleanup and async context manager support to HTTP clients.
82
+
83
+ ### Bug fixes
84
+ * Stream aiohttp response bodies incrementally to enable true output event streams.
85
+ * Fixed `AIOHTTPClient` to stop dropping valueless query parameters and automatically adding a `Content-Type` to bodyless POST, PUT, and PATCH requests.
86
+ * Fixed duplicate Content-Type headers when a member is bound to Content-Type.
87
+
88
+ ## v0.4.4
89
+
90
+ ### Enhancements
91
+ * Added a protocol hook for extracting server-provided retry delays from error responses.
92
+ * Declared `AWSCRTHTTPClient` as duplex (bidirectional) streaming capable via `SUPPORTS_DUPLEX_STREAMING`. `AIOHTTPClient` explicitly does not support duplex streaming.
93
+ * Disabled automatic redirects in `AIOHTTPClient` so that redirect responses are returned to the caller instead of being followed transparently.
94
+
95
+ ## v0.4.3
96
+
97
+ ### Enhancements
98
+ * Enabled HTTP binding protocols to resolve modeled response errors when wire identifiers do not exactly match registered shape IDs. ([#742](https://github.com/smithy-lang/smithy-python/pull/742))
99
+
100
+ ### Bug fixes
101
+ * Fixed `AIOHTTPClient` sending omitted request payloads with chunked transfer encoding.
102
+
103
+ ## v0.4.2
104
+
105
+ ### Bug fixes
106
+ * Disabled automatic response decompression in `AIOHTTPClient`.
107
+
108
+ ## v0.4.1
109
+
110
+ ### Bug fixes
111
+ * Fixed `AWSCRTHTTPClient` to send HTTP/1.1 request bodies via `body_stream` instead of the HTTP/2-only `request_body_generator`.
112
+
113
+ ## v0.4.0
114
+
115
+ ### Breaking Changes
116
+ * Replace `FieldPosition` enum values with string literals for `Field.kind`. Use "header" and "trailer" instead of `FieldPosition.HEADER` and `FieldPosition.TRAILER`.
117
+
118
+ ### Dependencies
119
+ * Upgrade CRT to 0.32.0 to fix bug where HTTP2 exceptions could hang indefinitely
120
+
121
+ ## v0.3.1
122
+
123
+ ### Bug fixes
124
+ * Fixed empty error messaging for CRT-based timeout errors.
125
+
126
+ ### Dependencies
127
+ * Removed strict pinning on `smithy-core` in favor of client managed versions.
128
+
129
+ ## v0.3.0
130
+
131
+ ### Features
132
+ * Added `MockHTTPClient` for testing SDK clients without making real HTTP requests.
133
+
134
+ ### Enhancements
135
+ * Added timeout error detection for HTTP clients
136
+
137
+ ### Dependencies
138
+ * Bump `smithy-core` from `~=0.1.0` to `~=0.2.0`.
139
+
140
+ ## v0.2.1
141
+
142
+ ### Bug fixes
143
+ * Add port to CRT HTTP client's host header.
144
+
145
+ ## v0.2.0
146
+
147
+ ### Breaking Changes
148
+ * Update `AWSCRTHTTPClient` to integrate with the new AWS CRT async interfaces. ([#573](https://github.com/smithy-lang/smithy-python/pull/573)). The `AWSCRTHTTPResponse` constructor now accepts a `stream` argument of type `awscrt.aio.http.AIOHttpClientStreamUnified`. Additionally, the following classes were removed: `CRTResponseBody`, `CRTResponseFactory`, and `BufferableByteStream`.
149
+
150
+ ## v0.1.0
151
+
152
+ ### Breaking Changes
153
+ * Removed identity and auth interfaces in favor of the transport-agnostic interfaces introduced in `smithy-core`.
154
+
155
+ ### Features
156
+ * Introduced schema-based serializers and deserializers for HTTP binding protocols.
157
+
158
+ ## v0.0.1
159
+
160
+ ### Features
161
+ * Added support for aiohttp and AWSCRT http clients.
162
+ * Added basic HTTP primitives and interfaces for Smithy clients.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: smithy-http
3
- Version: 0.6.0
3
+ Version: 0.8.0
4
4
  Summary: HTTP components for Smithy tooling.
5
5
  Project-URL: Changelog, https://github.com/smithy-lang/smithy-python/blob/develop/packages/smithy-http/CHANGELOG.md
6
6
  Project-URL: Code, https://github.com/smithy-lang/smithy-python/blob/develop/packages/smithy-http/
@@ -21,18 +21,25 @@ Classifier: Programming Language :: Python :: 3 :: Only
21
21
  Classifier: Programming Language :: Python :: 3.12
22
22
  Classifier: Programming Language :: Python :: 3.13
23
23
  Classifier: Programming Language :: Python :: 3.14
24
+ Classifier: Programming Language :: Python :: 3.15
24
25
  Classifier: Programming Language :: Python :: Free Threading :: 2 - Beta
25
26
  Classifier: Programming Language :: Python :: Implementation :: CPython
26
27
  Classifier: Topic :: Software Development :: Libraries
27
28
  Requires-Python: >=3.12
28
- Requires-Dist: smithy-core
29
+ Requires-Dist: smithy-core~=0.11.0
29
30
  Provides-Extra: aiohttp
30
31
  Requires-Dist: aiohttp<4.0,>=3.11.12; extra == 'aiohttp'
31
- Requires-Dist: yarl; extra == 'aiohttp'
32
+ Requires-Dist: yarl>=1.17.0; extra == 'aiohttp'
32
33
  Provides-Extra: awscrt
33
34
  Requires-Dist: awscrt~=0.32.0; extra == 'awscrt'
34
35
  Provides-Extra: cbor
35
- Requires-Dist: smithy-cbor~=0.1.0; extra == 'cbor'
36
+ Requires-Dist: smithy-cbor~=0.3.0; extra == 'cbor'
37
+ Provides-Extra: eventstream
38
+ Requires-Dist: smithy-aws-event-stream~=0.5.0; extra == 'eventstream'
39
+ Provides-Extra: json
40
+ Requires-Dist: smithy-json~=0.5.0; extra == 'json'
41
+ Provides-Extra: urllib3
42
+ Requires-Dist: urllib3<3.0,>=2.0; extra == 'urllib3'
36
43
  Description-Content-Type: text/markdown
37
44
 
38
45
  # smithy-http
@@ -47,11 +54,14 @@ The `smithy_http.testing` module provides shared utilities for testing HTTP func
47
54
 
48
55
  ### MockHTTPClient
49
56
 
50
- The `MockHTTPClient` allows you to test smithy-python clients without making actual network calls. It implements the `HTTPClient` interface and provides configurable responses for functional testing.
57
+ `MockHTTPClient` lets you test smithy-python clients without making actual network
58
+ calls. It implements the `HTTPClient` interface and returns queued responses. For async
59
+ clients, use `smithy_http.aio.testing.AsyncMockHTTPClient`, which implements
60
+ `AsyncHTTPClient` the same way.
51
61
 
52
- #### Basic Usage
62
+ #### Basic Usage
53
63
 
54
- ```python
64
+ ```python
55
65
  from smithy_http.testing import MockHTTPClient
56
66
 
57
67
  # Create mock client and configure responses
@@ -67,7 +77,7 @@ config = Config(transport=mock_client)
67
77
  client = TestSmithyServiceClient(config=config)
68
78
 
69
79
  # Test your client logic
70
- result = await client.some_operation({"input": "data"})
80
+ result = client.some_operation({"input": "data"})
71
81
 
72
82
  # Inspect what requests were made
73
83
  assert mock_client.call_count == 1
@@ -10,11 +10,14 @@ The `smithy_http.testing` module provides shared utilities for testing HTTP func
10
10
 
11
11
  ### MockHTTPClient
12
12
 
13
- The `MockHTTPClient` allows you to test smithy-python clients without making actual network calls. It implements the `HTTPClient` interface and provides configurable responses for functional testing.
13
+ `MockHTTPClient` lets you test smithy-python clients without making actual network
14
+ calls. It implements the `HTTPClient` interface and returns queued responses. For async
15
+ clients, use `smithy_http.aio.testing.AsyncMockHTTPClient`, which implements
16
+ `AsyncHTTPClient` the same way.
14
17
 
15
- #### Basic Usage
18
+ #### Basic Usage
16
19
 
17
- ```python
20
+ ```python
18
21
  from smithy_http.testing import MockHTTPClient
19
22
 
20
23
  # Create mock client and configure responses
@@ -30,7 +33,7 @@ config = Config(transport=mock_client)
30
33
  client = TestSmithyServiceClient(config=config)
31
34
 
32
35
  # Test your client logic
33
- result = await client.some_operation({"input": "data"})
36
+ result = client.some_operation({"input": "data"})
34
37
 
35
38
  # Inspect what requests were made
36
39
  assert mock_client.call_count == 1
@@ -22,12 +22,13 @@ classifiers = [
22
22
  "Programming Language :: Python :: 3.12",
23
23
  "Programming Language :: Python :: 3.13",
24
24
  "Programming Language :: Python :: 3.14",
25
+ "Programming Language :: Python :: 3.15",
25
26
  "Programming Language :: Python :: Implementation :: CPython",
26
27
  "Programming Language :: Python :: Free Threading :: 2 - Beta",
27
28
  "Topic :: Software Development :: Libraries"
28
29
  ]
29
30
  dependencies = [
30
- "smithy-core",
31
+ "smithy-core~=0.11.0",
31
32
  ]
32
33
 
33
34
  [project.urls]
@@ -40,11 +41,20 @@ awscrt = [
40
41
  "awscrt~=0.32.0",
41
42
  ]
42
43
  cbor = [
43
- "smithy-cbor~=0.1.0",
44
+ "smithy-cbor~=0.3.0",
45
+ ]
46
+ json = [
47
+ "smithy-json~=0.5.0",
48
+ ]
49
+ eventstream = [
50
+ "smithy-aws-event-stream~=0.5.0",
44
51
  ]
45
52
  aiohttp = [
46
53
  "aiohttp>=3.11.12, <4.0",
47
- "yarl"
54
+ "yarl>=1.17.0",
55
+ ]
56
+ urllib3 = [
57
+ "urllib3>=2.0, <3.0",
48
58
  ]
49
59
 
50
60
  [build-system]