Skip to content

Commit fe2ed57

Browse files
authored
Merge branch 'openapi-generators:main' into main
2 parents de4249b + 7939364 commit fe2ed57

68 files changed

Lines changed: 1102 additions & 1591 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.changeset/add_support_for_x_enum_varnames_to_string_enums.md

Lines changed: 0 additions & 9 deletions
This file was deleted.

.github/workflows/checks.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
test:
1212
strategy:
1313
matrix:
14-
python: [ "3.10", "3.11", "3.12", "3.13", "3.14" ]
14+
python: [ "3.11", "3.12", "3.13", "3.14" ]
1515
os: [ ubuntu-latest, macos-latest, windows-latest ]
1616
runs-on: ${{ matrix.os }}
1717
steps:
@@ -37,7 +37,7 @@ jobs:
3737
run: pip install pdm
3838

3939
- name: Install Dependencies
40-
run: pdm install
40+
run: pdm sync --clean
4141

4242
- name: Check formatting
4343
run: pdm run ruff format . --check
@@ -60,7 +60,7 @@ jobs:
6060
if: matrix.os == 'ubuntu-latest'
6161

6262
- name: Store coverage report
63-
uses: actions/upload-artifact@v7.0.0
63+
uses: actions/upload-artifact@v7.0.1
6464
if: matrix.os == 'ubuntu-latest'
6565
with:
6666
name: coverage-${{ matrix.python }}
@@ -78,7 +78,7 @@ jobs:
7878
- name: Set up Python
7979
uses: actions/setup-python@v6.2.0
8080
with:
81-
python-version: "3.10"
81+
python-version: "3.11"
8282

8383
- name: Get Python Version
8484
id: get_python_version
@@ -96,7 +96,7 @@ jobs:
9696
run: pip install pdm
9797

9898
- name: Install minimum dependencies
99-
run: pdm install -L pdm.minimal.lock
99+
run: pdm sync --clean -L pdm.minimal.lock
100100

101101
- name: Run mypy
102102
run: pdm mypy --show-error-codes
@@ -139,7 +139,7 @@ jobs:
139139
.venv/bin/python -m coverage report --fail-under=100
140140
141141
- name: Upload HTML report if check failed.
142-
uses: actions/upload-artifact@v7.0.0
142+
uses: actions/upload-artifact@v7.0.1
143143
with:
144144
name: html-report
145145
path: htmlcov
@@ -163,7 +163,7 @@ jobs:
163163
- name: Set up Python
164164
uses: actions/setup-python@v6.2.0
165165
with:
166-
python-version: "3.10"
166+
python-version: "3.11"
167167
- name: Get Python Version
168168
id: get_python_version
169169
run: echo "python_version=$(python --version)" >> $GITHUB_OUTPUT
@@ -178,7 +178,7 @@ jobs:
178178
run: |
179179
cd integration-tests
180180
pip install pdm
181-
pdm install -L ${{ matrix.lockfile }}
181+
pdm sync --clean -L ${{ matrix.lockfile }}
182182
- name: Run Tests
183183
run: |
184184
cd integration-tests

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ jobs:
1818
- name: Build
1919
run: hatchling build
2020
- name: Push to PyPI
21-
uses: pypa/gh-action-pypi-publish@v1.13.0
21+
uses: pypa/gh-action-pypi-publish@v1.14.0
2222
with:
2323
attestations: true

CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,34 @@ Programmatic usage of this project (e.g., importing it as a Python module) and t
1313

1414
The 0.x prefix used in versions for this project is to indicate that breaking changes are expected frequently (several times a year). Breaking changes will increment the minor number, all other changes will increment the patch number. You can track the progress toward 1.0 [here](https://github.com/openapi-generators/openapi-python-client/projects/2).
1515

16+
## 0.29.0 (2026-05-30)
17+
18+
### Breaking Changes
19+
20+
- Drop support for Python 3.10
21+
- Raise minimum httpx version to 0.23.1
22+
23+
### Features
24+
25+
- replace python-dateutil with stdlib datetime.fromisoformat (#1429)
26+
27+
### Fixes
28+
29+
- Remove some generated casts that aren't necessary with mypy v2 (#1436)
30+
- Explicitly set boundary for multipart/form-data (#1005)
31+
32+
## 0.28.4 (2026-05-11)
33+
34+
### Features
35+
36+
- Update `uv_build` to 0.11 when using `--meta=uv` (#1434)
37+
38+
#### Add support for x-enum-varnames to string enums
39+
40+
##1358 by @mbbush
41+
42+
You can now customize the variable names of the generated string enumerations using the x-enum-varnames openapi extension. Previously, this was only possible for integer enumerations.
43+
1644
## 0.28.3 (2026-02-17)
1745

1846
### Fixes

end_to_end_tests/docstrings-on-attributes-golden-record/pyproject.toml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,9 @@ packages = [
1010
include = ["my_test_api_client/py.typed"]
1111

1212
[tool.poetry.dependencies]
13-
python = "^3.10"
14-
httpx = ">=0.23.0,<0.29.0"
13+
python = "^3.11"
14+
httpx = ">=0.23.1,<0.29.0"
1515
attrs = ">=22.2.0"
16-
python-dateutil = "^2.8.0"
1716

1817
[build-system]
1918
requires = ["poetry-core>=2.0.0,<3.0.0"]

end_to_end_tests/functional_tests/generated_code_execution/test_defaults.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def test_defaults_in_initializer(self, MyModel):
5151
number_prop=1.5,
5252
int_prop=2,
5353
date_prop=datetime.date(2024, 1, 2),
54-
date_time_prop=datetime.datetime(2024, 1, 2, 3, 4, 5, tzinfo=datetime.timezone.utc),
54+
date_time_prop=datetime.datetime(2024, 1, 2, 3, 4, 5, tzinfo=datetime.UTC),
5555
uuid_prop=uuid.UUID("07EF8B4D-AA09-4FFA-898D-C710796AFF41"),
5656
any_prop_with_string="b",
5757
any_prop_with_int=3,

end_to_end_tests/functional_tests/generated_code_execution/test_properties.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def test_date(self, MyModel):
166166
assert_model_decode_encode(MyModel, json_data, MyModel(date_prop=date_value))
167167

168168
def test_date_time(self, MyModel):
169-
date_time_value = datetime.datetime.now(datetime.timezone.utc)
169+
date_time_value = datetime.datetime.now(datetime.UTC)
170170
json_data = {"dateTimeProp": date_time_value.isoformat()}
171171
assert_model_decode_encode(MyModel, json_data, MyModel(date_time_prop=date_time_value))
172172

end_to_end_tests/functional_tests/helpers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from typing import Any, Dict
22
import re
33

4-
from click.testing import Result
4+
from typer.testing import Result
55
import pytest
66

77
from end_to_end_tests.generated_client import generate_client_from_inline_spec, GeneratedClientContext

end_to_end_tests/generated_client.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@
99

1010
from attrs import define
1111
import pytest
12-
from click.testing import Result
13-
from typer.testing import CliRunner
12+
from typer.testing import CliRunner, Result
1413

1514
from openapi_python_client.cli import app
1615

end_to_end_tests/golden-record/my_test_api_client/api/bodies/post_bodies_multiple.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,16 @@ def _get_kwargs(
3030
if isinstance(body, File):
3131
if not isinstance(body, Unset):
3232
_kwargs["content"] = body.payload
33-
3433
headers["Content-Type"] = "application/octet-stream"
3534
if isinstance(body, PostBodiesMultipleDataBody):
3635
if not isinstance(body, Unset):
3736
_kwargs["data"] = body.to_dict()
38-
3937
headers["Content-Type"] = "application/x-www-form-urlencoded"
4038
if isinstance(body, PostBodiesMultipleFilesBody):
4139
if not isinstance(body, Unset):
4240
_kwargs["files"] = body.to_multipart()
4341

44-
headers["Content-Type"] = "multipart/form-data"
42+
headers["Content-Type"] = "multipart/form-data; boundary=+++"
4543

4644
_kwargs["headers"] = headers
4745
return _kwargs

0 commit comments

Comments
 (0)