From 61c8d1b4f0d79570c17ff2d70362d6f1d4dba623 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Mon, 18 Aug 2025 00:53:56 +0000 Subject: [PATCH 1/2] feat(api): api update --- .stats.yml | 4 ++-- src/benchify/resources/fixer.py | 20 ++++++++++---------- src/benchify/types/fixer_run_params.py | 9 ++++----- src/benchify/types/fixer_run_response.py | 7 ++----- tests/api_resources/test_fixer.py | 2 ++ 5 files changed, 20 insertions(+), 22 deletions(-) diff --git a/.stats.yml b/.stats.yml index 37094d2..852af64 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 1 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/benchify%2Fbenchify-bc04cfa7474038d34bb40a706e3c5f05f3a57fbc2668912f9b7885050c82f5c9.yml -openapi_spec_hash: c87647579ee434390bb0aba78cfb7bc1 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/benchify%2Fbenchify-882428dc42061ac58fad8814f920a7afec0a8fb54bb744e8e709b27156b8afb3.yml +openapi_spec_hash: 4778a24a07fa3aafa7a9befb36579c19 config_hash: 935baad1727a1116efdc14e9ce6e4405 diff --git a/src/benchify/resources/fixer.py b/src/benchify/resources/fixer.py index f3a66ca..fc87c29 100644 --- a/src/benchify/resources/fixer.py +++ b/src/benchify/resources/fixer.py @@ -48,11 +48,8 @@ def run( self, *, files: Iterable[fixer_run_params.File], - fix_types: List[ - Literal[ - "import_export", "string_literals", "ts_suggestions", "css", "tailwind", "react", "ai_fallback", "types" - ] - ] + bundle: bool | NotGiven = NOT_GIVEN, + fix_types: List[Literal["import_export", "string_literals", "css", "tailwind", "ai_fallback", "types"]] | NotGiven = NOT_GIVEN, fixes: Optional[fixer_run_params.Fixes] | NotGiven = NOT_GIVEN, meta: Optional[fixer_run_params.Meta] | NotGiven = NOT_GIVEN, @@ -71,6 +68,8 @@ def run( Args: files: List of files to process + bundle: Whether to bundle the project (experimental) + fix_types: Configuration for which fix types to apply fixes: DEPRECATED: legacy boolean flags for which fixes to apply. @@ -94,6 +93,7 @@ def run( body=maybe_transform( { "files": files, + "bundle": bundle, "fix_types": fix_types, "fixes": fixes, "meta": meta, @@ -133,11 +133,8 @@ async def run( self, *, files: Iterable[fixer_run_params.File], - fix_types: List[ - Literal[ - "import_export", "string_literals", "ts_suggestions", "css", "tailwind", "react", "ai_fallback", "types" - ] - ] + bundle: bool | NotGiven = NOT_GIVEN, + fix_types: List[Literal["import_export", "string_literals", "css", "tailwind", "ai_fallback", "types"]] | NotGiven = NOT_GIVEN, fixes: Optional[fixer_run_params.Fixes] | NotGiven = NOT_GIVEN, meta: Optional[fixer_run_params.Meta] | NotGiven = NOT_GIVEN, @@ -156,6 +153,8 @@ async def run( Args: files: List of files to process + bundle: Whether to bundle the project (experimental) + fix_types: Configuration for which fix types to apply fixes: DEPRECATED: legacy boolean flags for which fixes to apply. @@ -179,6 +178,7 @@ async def run( body=await async_maybe_transform( { "files": files, + "bundle": bundle, "fix_types": fix_types, "fixes": fixes, "meta": meta, diff --git a/src/benchify/types/fixer_run_params.py b/src/benchify/types/fixer_run_params.py index f49f887..70f83e2 100644 --- a/src/benchify/types/fixer_run_params.py +++ b/src/benchify/types/fixer_run_params.py @@ -14,11 +14,10 @@ class FixerRunParams(TypedDict, total=False): files: Required[Iterable[File]] """List of files to process""" - fix_types: List[ - Literal[ - "import_export", "string_literals", "ts_suggestions", "css", "tailwind", "react", "ai_fallback", "types" - ] - ] + bundle: bool + """Whether to bundle the project (experimental)""" + + fix_types: List[Literal["import_export", "string_literals", "css", "tailwind", "ai_fallback", "types"]] """Configuration for which fix types to apply""" fixes: Optional[Fixes] diff --git a/src/benchify/types/fixer_run_response.py b/src/benchify/types/fixer_run_response.py index d1fa388..a49d77d 100644 --- a/src/benchify/types/fixer_run_response.py +++ b/src/benchify/types/fixer_run_response.py @@ -45,14 +45,11 @@ class DataSuggestedChangesAllFilesFormat(BaseModel): class Data(BaseModel): - files_processed: int - """Number of files processed""" - status: DataStatus """Final per-file status after fixing""" - fixed_files: Optional[Dict[str, object]] = None - """Information about fixed files""" + bundled_files: Optional[List[FileChange]] = None + """Bundled files""" suggested_changes: Optional[DataSuggestedChanges] = None """Changes made by the fixer in the requested format""" diff --git a/tests/api_resources/test_fixer.py b/tests/api_resources/test_fixer.py index 9951734..2d58b81 100644 --- a/tests/api_resources/test_fixer.py +++ b/tests/api_resources/test_fixer.py @@ -40,6 +40,7 @@ def test_method_run_with_all_params(self, client: Benchify) -> None: "path": "x", } ], + bundle=True, fix_types=["import_export"], fixes={ "css": True, @@ -120,6 +121,7 @@ async def test_method_run_with_all_params(self, async_client: AsyncBenchify) -> "path": "x", } ], + bundle=True, fix_types=["import_export"], fixes={ "css": True, From e77452127ecd0673d28e107a38a03b9b709f8473 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Mon, 18 Aug 2025 00:54:08 +0000 Subject: [PATCH 2/2] release: 0.3.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 8 ++++++++ pyproject.toml | 2 +- src/benchify/_version.py | 2 +- 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 10f3091..6b7b74c 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.2.0" + ".": "0.3.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 59c521d..63f4c90 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 0.3.0 (2025-08-18) + +Full Changelog: [v0.2.0...v0.3.0](https://github.com/Benchify/benchify-sdk-python/compare/v0.2.0...v0.3.0) + +### Features + +* **api:** api update ([61c8d1b](https://github.com/Benchify/benchify-sdk-python/commit/61c8d1b4f0d79570c17ff2d70362d6f1d4dba623)) + ## 0.2.0 (2025-08-18) Full Changelog: [v0.1.3...v0.2.0](https://github.com/Benchify/benchify-sdk-python/compare/v0.1.3...v0.2.0) diff --git a/pyproject.toml b/pyproject.toml index 6b540c2..194096a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "benchify" -version = "0.2.0" +version = "0.3.0" description = "The official Python library for the benchify API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/benchify/_version.py b/src/benchify/_version.py index 8d49de9..c7dc4f7 100644 --- a/src/benchify/_version.py +++ b/src/benchify/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "benchify" -__version__ = "0.2.0" # x-release-please-version +__version__ = "0.3.0" # x-release-please-version