diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 39804a04..0f70372f 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,24 +1,24 @@ lockVersion: 2.0.0 id: 833c6a67-4a4a-4ef1-ba24-165a29264e4a management: - docChecksum: d371b25645aaa9583b5e8f0ebf5c304a + docChecksum: 46b4d2013a6245328a9b950541ace539 docVersion: 1.0.0 - speakeasyVersion: 1.795.3 - generationVersion: 2.932.9 - releaseVersion: 2.4.0 - configChecksum: 208685cdfcee7c058c1f2f4d49d16785 + speakeasyVersion: 1.796.0 + generationVersion: 2.932.15 + releaseVersion: 2.4.1 + configChecksum: 34b34597d28eb1155e00470992f1c968 repoURL: https://github.com/gr4vy/gr4vy-python.git installationURL: https://github.com/gr4vy/gr4vy-python.git published: true persistentEdits: - generation_id: 6c362b4f-588e-4f5e-af84-171a9425ce66 - pristine_commit_hash: b632801aa5d9955dd1fd0623fef832ec0d0e24b6 - pristine_tree_hash: 1794451c565ff88d179ce8fb82403cabc45e5db0 + generation_id: 070f8038-cae4-4740-b0a3-4ce2f4f2cb6c + pristine_commit_hash: d580247e7bcf97f7d38418d9679757c821016dca + pristine_tree_hash: 602498548ada8fb0d764f85b1562df7497151d68 features: python: additionalDependencies: 1.1.0 constsAndDefaults: 1.0.7 - core: 6.1.0 + core: 6.1.2 defaultEnabledRetries: 0.2.0 deprecations: 3.0.2 enumUnions: 0.1.1 @@ -38,7 +38,7 @@ features: openEnums: 1.0.4 pagination: 3.0.10 responseFormat: 1.1.0 - retries: 3.1.0 + retries: 3.1.1 sdkHooks: 1.3.0 serverIDs: 3.0.0 unions: 3.1.9 @@ -1481,8 +1481,8 @@ trackedFiles: pristine_git_object: 1b00d4286fb5038d3f3932064c67781f6a37f68c docs/models/listpaymentservicesrequest.md: id: 0bd6afaaec74 - last_write_checksum: sha1:f5b578ec4bb198e2155c3b67c3c16cd01d8d6bb9 - pristine_git_object: 99c095bf84ce43d339e3321d43ee8b62e73091b5 + last_write_checksum: sha1:6c15ed5c9e9a9930fd1945ae4870e6c919d6fb21 + pristine_git_object: a161b7b18ea05d8736de1f7581d642c8ddd06540 docs/models/listpaymentservicesresponse.md: id: 234a36467b45 last_write_checksum: sha1:cf3984646273bb9edd9424226b374a09ebd3829e @@ -2813,8 +2813,8 @@ trackedFiles: pristine_git_object: 868d80fc57d649914d4bc80d71f9a20d4a4ee761 docs/sdks/paymentservicessdk/README.md: id: a24bcb6f30a4 - last_write_checksum: sha1:97024e98f7748786fe175da4beecdc6340a0b830 - pristine_git_object: 9e624c8c04888d2410f8314e30af029122ddbc66 + last_write_checksum: sha1:e45fcfa8846560c32202509d8bc65ee769fc373c + pristine_git_object: b88c5be51dd01ad3986b5299257649877b86453f docs/sdks/payouts/README.md: id: 184ed4a74471 last_write_checksum: sha1:d9f3c8f0df9ff0f8404d10b50b723b7b39af4105 @@ -2877,8 +2877,8 @@ trackedFiles: pristine_git_object: cb9c15d314c1930557401074329ed7a737147919 pyproject.toml: id: 5d07e7d72637 - last_write_checksum: sha1:25424a27bd10aee8d320e829ac31b06748b6efc6 - pristine_git_object: 1c243fb7e226deadab7620da7c48db44b707333d + last_write_checksum: sha1:2d5562f3215eb8c89aff8f66bcc6aef80d59222d + pristine_git_object: 3d0ee6bf4b879c1f084b2ed072ff4161c2e78f37 scripts/prepare_readme.py: id: e0c5957a6035 last_write_checksum: sha1:63a92abbd1de3323613f0d4c1ae4412076577710 @@ -2905,8 +2905,8 @@ trackedFiles: pristine_git_object: f8ef109bb6a9dbe37d0a7092606176a0738986fd src/gr4vy/_version.py: id: 1b5ad1da47aa - last_write_checksum: sha1:8ca4856e7218a45e4fc97b572b8197050e4592c6 - pristine_git_object: a7e56104006c88a44c7eecb88e0b97d62b3c8cf7 + last_write_checksum: sha1:7f4e66142f34738363e8fc99ad5ee01cc95c016d + pristine_git_object: ebefc52619c272d5bd6ed2f7dd61316c3d007715 src/gr4vy/account_updater.py: id: 6dc8f39e2fb9 last_write_checksum: sha1:fabc79a59dd06fb927ce2d834fbafbcad5836a4b @@ -4033,8 +4033,8 @@ trackedFiles: pristine_git_object: 883c4723c7e6e12711f5570aa42be9571e73d9ae src/gr4vy/models/list_payment_servicesop.py: id: be713c450ec5 - last_write_checksum: sha1:d0b0fd1f1719d7ba1f192df4dce62e5df9c55b6c - pristine_git_object: b98f62c452d1f63033f9067cf2fc1c781209999d + last_write_checksum: sha1:c231ec33fe0192cd34cbe8f45bac3f95b52d6468 + pristine_git_object: 6fdd371b12060855adf6e7ce72cfffc7a3f4d031 src/gr4vy/models/list_payoutsop.py: id: 72a6630515f6 last_write_checksum: sha1:a374e13f7db429954e90bf3438dd38e752c39bd1 @@ -5001,8 +5001,8 @@ trackedFiles: pristine_git_object: 79b53149b176dcdb1c84fa943decb4de2c9aa316 src/gr4vy/payment_services_sdk.py: id: 2d6fb11197ef - last_write_checksum: sha1:23e43a11d79af29574856405ef68042c6cc483d8 - pristine_git_object: 9cb6f0186a29c5a9a8f2c38f1d62877454fd4225 + last_write_checksum: sha1:79169dea650c6ad464df7adffb237cd6d1554a6e + pristine_git_object: 4b0cc7fded47c3a501eaa19897a21e52fa601963 src/gr4vy/payouts.py: id: 2c9652ed3beb last_write_checksum: sha1:6370120b4018fc95746aaa592b39e4f8ef151189 @@ -5125,8 +5125,8 @@ trackedFiles: pristine_git_object: 591415af8e64baa410627b507d2740afb5387d13 src/gr4vy/utils/retries.py: id: c486412ce323 - last_write_checksum: sha1:481dfc7cd6a07a3987f0f443e91bee72888ae41d - pristine_git_object: c7418a62826fc73990a52e70df0d54093c5e2a57 + last_write_checksum: sha1:251e4dd969bb6c06025afe1bad1b5035e94c2060 + pristine_git_object: 406c1e7c36c7a4fa4fb48bb567d254e2803e1792 src/gr4vy/utils/security.py: id: 648156d4ba48 last_write_checksum: sha1:8f2a2aef55d9cf6eb91a7a752d3b22ff83e98312 @@ -7337,6 +7337,7 @@ examples: limit: 20 deleted: true application_name: "core-api" + include_fields: true header: x-gr4vy-merchant-account-id: "default" responses: @@ -9456,7 +9457,9 @@ examples: application/json: {"type": "error", "code": "gateway_timeout", "status": 504, "message": "Request could not be processed"} examplesVersion: 1.0.2 generatedTests: {} -releaseNotes: "## Python SDK Changes:\n* `gr4vy.buyers.payment_methods.list()`: `response.items[].method.enum(duitnow)` **Added**\n* `gr4vy.payment_methods.list()`: `response.items[].method.enum(duitnow)` **Added**\n* `gr4vy.payment_methods.create()`: \n * `request_body.union(RedirectPaymentMethodCreate).method.enum(duitnow)` **Added**\n * `response.method.enum(duitnow)` **Added**\n* `gr4vy.payment_methods.get()`: `response.method.enum(duitnow)` **Added**\n* `gr4vy.payment_methods.update()`: `response.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.list()`: \n * `request.method` **Changed**\n * `response.items[].payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.create()`: \n * `request.payment_method.union(RedirectPaymentMethodCreate).method.enum(duitnow)` **Added**\n * `response.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.get()`: `response.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.update()`: `response.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.capture()`: `response.union(Transaction).payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.void()`: `response.union(Transaction).payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.cancel()`: `response.transaction.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.sync()`: `response.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.transactions.increment_authorization()`: `response.transaction.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.payment_service_definitions.list()`: `response.items[].method.enum(duitnow)` **Added**\n* `gr4vy.payment_service_definitions.get()`: `response.method.enum(duitnow)` **Added**\n* `gr4vy.payment_services.list()`: \n * `request.method` **Changed**\n * `response.items[].method.enum(duitnow)` **Added**\n* `gr4vy.payment_services.create()`: `response.method.enum(duitnow)` **Added**\n* `gr4vy.payment_services.get()`: `response.method.enum(duitnow)` **Added**\n* `gr4vy.payment_services.update()`: `response.method.enum(duitnow)` **Added**\n* `gr4vy.payouts.list()`: `response.items[].payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.payouts.create()`: `response.payment_method.method.enum(duitnow)` **Added**\n* `gr4vy.payouts.get()`: `response.payment_method.method.enum(duitnow)` **Added**\n" +releaseNotes: | + ## Python SDK Changes: + * `gr4vy.payment_services.list()`: `request.include_fields` **Added** generatedFiles: - .gitattributes - .vscode/settings.json diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 85b6e82b..e5a8fd93 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -29,7 +29,7 @@ generation: generateNewTests: false skipResponseBodyAssertions: false python: - version: 2.4.0 + version: 2.4.1 additionalDependencies: dev: freezegun: ^1.5.1 diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index b1353e64..1043c112 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,9 +1,9 @@ -speakeasyVersion: 1.795.3 +speakeasyVersion: 1.796.0 sources: openapi: sourceNamespace: openapi - sourceRevisionDigest: sha256:6d7f4985d61b643384ef261810f40831be1e5bd198369d93e83088aca78563ad - sourceBlobDigest: sha256:8402a94cb39de7296f62496c3e64b8bd65d613f49e05253d47ddcfbede801cd6 + sourceRevisionDigest: sha256:43ba243bef9195c81ec91a2a1aa4875e103ae1ceac9c4df86215bbff72448f2b + sourceBlobDigest: sha256:4b06a4ca62986f3e64fb1513dcca0242e879ec71c44d2211ceaadbac5596e1f5 tags: - latest - 1.0.0 @@ -11,10 +11,10 @@ targets: python: source: openapi sourceNamespace: openapi - sourceRevisionDigest: sha256:6d7f4985d61b643384ef261810f40831be1e5bd198369d93e83088aca78563ad - sourceBlobDigest: sha256:8402a94cb39de7296f62496c3e64b8bd65d613f49e05253d47ddcfbede801cd6 + sourceRevisionDigest: sha256:43ba243bef9195c81ec91a2a1aa4875e103ae1ceac9c4df86215bbff72448f2b + sourceBlobDigest: sha256:4b06a4ca62986f3e64fb1513dcca0242e879ec71c44d2211ceaadbac5596e1f5 codeSamplesNamespace: openapi-python-code-samples - codeSamplesRevisionDigest: sha256:52eec9c55d6882b8455e7c9d641c158ea44f40d5787d00d947ae46fb36019ad9 + codeSamplesRevisionDigest: sha256:4474d767f8663834b0f357465e7020cd7cd88323df6cb846ea8018368e5f15e5 workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/RELEASES.md b/RELEASES.md index 45778710..f701d333 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -2468,4 +2468,14 @@ Based on: ### Generated - [python v2.4.0] . ### Releases -- [PyPI v2.4.0] https://pypi.org/project/gr4vy/2.4.0 - . \ No newline at end of file +- [PyPI v2.4.0] https://pypi.org/project/gr4vy/2.4.0 - . + +## 2026-08-27 11:18:25 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.796.0 (2.932.15) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v2.4.1] . +### Releases +- [PyPI v2.4.1] https://pypi.org/project/gr4vy/2.4.1 - . \ No newline at end of file diff --git a/docs/models/listpaymentservicesrequest.md b/docs/models/listpaymentservicesrequest.md index 99c095bf..a161b7b1 100644 --- a/docs/models/listpaymentservicesrequest.md +++ b/docs/models/listpaymentservicesrequest.md @@ -3,10 +3,11 @@ ## Fields -| Field | Type | Required | Description | Example | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `method` | [OptionalNullable[models.Method]](../models/method.md) | :heavy_minus_sign: | Return any payment service for this method. | | -| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | A pointer to the page of results to return. | ZXhhbXBsZTE | -| `limit` | *Optional[int]* | :heavy_minus_sign: | The maximum number of items that are at returned. | 20 | -| `deleted` | *OptionalNullable[bool]* | :heavy_minus_sign: | Return any deleted payment service. | true | -| `merchant_account_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the merchant account to use for this request. | default | \ No newline at end of file +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | +| `method` | [OptionalNullable[models.Method]](../models/method.md) | :heavy_minus_sign: | Return any payment service for this method. | | +| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | A pointer to the page of results to return. | ZXhhbXBsZTE | +| `limit` | *Optional[int]* | :heavy_minus_sign: | The maximum number of items that are at returned. | 20 | +| `deleted` | *OptionalNullable[bool]* | :heavy_minus_sign: | Return any deleted payment service. | true | +| `include_fields` | *Optional[bool]* | :heavy_minus_sign: | Include the non-secret credential and reporting fields for each payment service. Disable this to reduce response time if you don't need them. | true | +| `merchant_account_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the merchant account to use for this request. | default | \ No newline at end of file diff --git a/docs/sdks/paymentservicessdk/README.md b/docs/sdks/paymentservicessdk/README.md index 9e624c8c..b88c5be5 100644 --- a/docs/sdks/paymentservicessdk/README.md +++ b/docs/sdks/paymentservicessdk/README.md @@ -29,7 +29,7 @@ with Gr4vy( bearer_auth=os.getenv("GR4VY_BEARER_AUTH", ""), ) as g_client: - res = g_client.payment_services.list(cursor="ZXhhbXBsZTE", limit=20, deleted=True) + res = g_client.payment_services.list(cursor="ZXhhbXBsZTE", limit=20, deleted=True, include_fields=True) while res is not None: # Handle items @@ -40,14 +40,15 @@ with Gr4vy( ### Parameters -| Parameter | Type | Required | Description | Example | -| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `method` | [OptionalNullable[models.Method]](../../models/method.md) | :heavy_minus_sign: | Return any payment service for this method. | | -| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | A pointer to the page of results to return. | ZXhhbXBsZTE | -| `limit` | *Optional[int]* | :heavy_minus_sign: | The maximum number of items that are at returned. | 20 | -| `deleted` | *OptionalNullable[bool]* | :heavy_minus_sign: | Return any deleted payment service. | true | -| `merchant_account_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the merchant account to use for this request. | default | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | +| `method` | [OptionalNullable[models.Method]](../../models/method.md) | :heavy_minus_sign: | Return any payment service for this method. | | +| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | A pointer to the page of results to return. | ZXhhbXBsZTE | +| `limit` | *Optional[int]* | :heavy_minus_sign: | The maximum number of items that are at returned. | 20 | +| `deleted` | *OptionalNullable[bool]* | :heavy_minus_sign: | Return any deleted payment service. | true | +| `include_fields` | *Optional[bool]* | :heavy_minus_sign: | Include the non-secret credential and reporting fields for each payment service. Disable this to reduce response time if you don't need them. | true | +| `merchant_account_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the merchant account to use for this request. | default | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response diff --git a/pyproject.toml b/pyproject.toml index 1c243fb7..3d0ee6bf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "gr4vy" -version = "2.4.0" +version = "2.4.1" description = "Python Client SDK Generated by Speakeasy." authors = [{ name = "Gr4vy" },] readme = "README-PYPI.md" diff --git a/src/gr4vy/_version.py b/src/gr4vy/_version.py index a7e56104..ebefc526 100644 --- a/src/gr4vy/_version.py +++ b/src/gr4vy/_version.py @@ -3,10 +3,10 @@ import importlib.metadata __title__: str = "gr4vy" -__version__: str = "2.4.0" +__version__: str = "2.4.1" __openapi_doc_version__: str = "1.0.0" -__gen_version__: str = "2.932.9" -__user_agent__: str = "speakeasy-sdk/python 2.4.0 2.932.9 1.0.0 gr4vy" +__gen_version__: str = "2.932.15" +__user_agent__: str = "speakeasy-sdk/python 2.4.1 2.932.15 1.0.0 gr4vy" try: if __package__ is not None: diff --git a/src/gr4vy/models/list_payment_servicesop.py b/src/gr4vy/models/list_payment_servicesop.py index b98f62c4..6fdd371b 100644 --- a/src/gr4vy/models/list_payment_servicesop.py +++ b/src/gr4vy/models/list_payment_servicesop.py @@ -50,6 +50,8 @@ class ListPaymentServicesRequestTypedDict(TypedDict): r"""The maximum number of items that are at returned.""" deleted: NotRequired[Nullable[bool]] r"""Return any deleted payment service.""" + include_fields: NotRequired[bool] + r"""Include the non-secret credential and reporting fields for each payment service. Disable this to reduce response time if you don't need them.""" merchant_account_id: NotRequired[str] r"""The ID of the merchant account to use for this request.""" @@ -79,6 +81,12 @@ class ListPaymentServicesRequest(BaseModel): ] = UNSET r"""Return any deleted payment service.""" + include_fields: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = True + r"""Include the non-secret credential and reporting fields for each payment service. Disable this to reduce response time if you don't need them.""" + merchant_account_id: Annotated[ Optional[str], pydantic.Field(alias="x-gr4vy-merchant-account-id"), @@ -89,7 +97,14 @@ class ListPaymentServicesRequest(BaseModel): @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( - ["method", "cursor", "limit", "deleted", "merchant_account_id"] + [ + "method", + "cursor", + "limit", + "deleted", + "include_fields", + "merchant_account_id", + ] ) nullable_fields = set(["method", "cursor", "deleted"]) serialized = handler(self) diff --git a/src/gr4vy/payment_services_sdk.py b/src/gr4vy/payment_services_sdk.py index 9cb6f018..4b0cc7fd 100644 --- a/src/gr4vy/payment_services_sdk.py +++ b/src/gr4vy/payment_services_sdk.py @@ -18,6 +18,7 @@ def list( cursor: OptionalNullable[str] = UNSET, limit: Optional[int] = 20, deleted: OptionalNullable[bool] = UNSET, + include_fields: Optional[bool] = True, merchant_account_id: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -32,6 +33,7 @@ def list( :param cursor: A pointer to the page of results to return. :param limit: The maximum number of items that are at returned. :param deleted: Return any deleted payment service. + :param include_fields: Include the non-secret credential and reporting fields for each payment service. Disable this to reduce response time if you don't need them. :param merchant_account_id: The ID of the merchant account to use for this request. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -53,6 +55,7 @@ def list( cursor=cursor, limit=limit, deleted=deleted, + include_fields=include_fields, merchant_account_id=merchant_account_id, ) @@ -121,6 +124,7 @@ def next_func() -> Optional[models.ListPaymentServicesResponse]: cursor=next_cursor, limit=limit, deleted=deleted, + include_fields=include_fields, merchant_account_id=merchant_account_id, retries=retries, server_url=server_url, @@ -188,6 +192,7 @@ async def list_async( cursor: OptionalNullable[str] = UNSET, limit: Optional[int] = 20, deleted: OptionalNullable[bool] = UNSET, + include_fields: Optional[bool] = True, merchant_account_id: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -202,6 +207,7 @@ async def list_async( :param cursor: A pointer to the page of results to return. :param limit: The maximum number of items that are at returned. :param deleted: Return any deleted payment service. + :param include_fields: Include the non-secret credential and reporting fields for each payment service. Disable this to reduce response time if you don't need them. :param merchant_account_id: The ID of the merchant account to use for this request. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -223,6 +229,7 @@ async def list_async( cursor=cursor, limit=limit, deleted=deleted, + include_fields=include_fields, merchant_account_id=merchant_account_id, ) @@ -291,6 +298,7 @@ def next_func() -> Optional[models.ListPaymentServicesResponse]: cursor=next_cursor, limit=limit, deleted=deleted, + include_fields=include_fields, merchant_account_id=merchant_account_id, retries=retries, server_url=server_url, diff --git a/src/gr4vy/utils/retries.py b/src/gr4vy/utils/retries.py index c7418a62..406c1e7c 100644 --- a/src/gr4vy/utils/retries.py +++ b/src/gr4vy/utils/retries.py @@ -318,6 +318,7 @@ def retry_with_backoff( retry_after_ms = _parse_retry_after_ms_header(exception.response) if retry_after_ms is not None: exception.retry_after = retry_after_ms + exception.response.close() sleep = _get_sleep_interval( exception, initial_interval, @@ -358,6 +359,7 @@ async def retry_with_backoff_async( retry_after_ms = _parse_retry_after_ms_header(exception.response) if retry_after_ms is not None: exception.retry_after = retry_after_ms + await exception.response.aclose() sleep = _get_sleep_interval( exception, initial_interval,