diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 7f3f5c84..354c2fa8 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.23.0" + ".": "0.23.1" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index ac653af6..63ac0b34 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 0.23.1 (2024-07-29) + +Full Changelog: [v0.23.0...v0.23.1](https://github.com/Finch-API/finch-api-python/compare/v0.23.0...v0.23.1) + +### Chores + +* **internal:** add type construction helper ([#454](https://github.com/Finch-API/finch-api-python/issues/454)) ([c059838](https://github.com/Finch-API/finch-api-python/commit/c059838b36925567cea13220c84c59c2d399513d)) + ## 0.23.0 (2024-07-26) Full Changelog: [v0.22.3...v0.23.0](https://github.com/Finch-API/finch-api-python/compare/v0.22.3...v0.23.0) diff --git a/pyproject.toml b/pyproject.toml index 945825a9..b26975cd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "finch-api" -version = "0.23.0" +version = "0.23.1" description = "The official Python library for the Finch API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/finch/_models.py b/src/finch/_models.py index eb7ce3bd..5148d5a7 100644 --- a/src/finch/_models.py +++ b/src/finch/_models.py @@ -406,6 +406,15 @@ def build( return cast(_BaseModelT, construct_type(type_=base_model_cls, value=kwargs)) +def construct_type_unchecked(*, value: object, type_: type[_T]) -> _T: + """Loose coercion to the expected type with construction of nested values. + + Note: the returned value from this function is not guaranteed to match the + given type. + """ + return cast(_T, construct_type(value=value, type_=type_)) + + def construct_type(*, value: object, type_: object) -> object: """Loose coercion to the expected type with construction of nested values. diff --git a/src/finch/_version.py b/src/finch/_version.py index 96cb6868..124b85d6 100644 --- a/src/finch/_version.py +++ b/src/finch/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "finch" -__version__ = "0.23.0" # x-release-please-version +__version__ = "0.23.1" # x-release-please-version