Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout 🔁
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #v5.0.0

- name: Set up Python 🐍
uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 #v4.7.1
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c #v6.0.0
with:
python-version: "3.9"
python-version: "3.13"

- name: Install Poetry and pre-commit 💈
run: pip install poetry==1.8.5 pre-commit
Expand All @@ -34,7 +34,7 @@ jobs:
run: poetry build

- name: Publish build artifact ⬆️
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 #v4.3.1
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 #v5.0.0
with:
name: package-dist
path: dist
Expand All @@ -48,10 +48,10 @@ jobs:
id-token: write
steps:
- name: Download build artifact ⬇️
uses: actions/download-artifact@eaceaf801fd36c7dee90939fad912460b18a1ffe #v4.1.2
uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 #v6.0.0
with:
name: package-dist
path: dist

- name: Publish package to PyPI 🙌
uses: pypa/gh-action-pypi-publish@2f6f737ca5f74c637829c0f5c3acd0e29ea5e8bf #v1.8.11
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e #v1.13.0
4 changes: 2 additions & 2 deletions .github/workflows/test_latest_python.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ jobs:
python-version: ["3.14"]
steps:
- name: Checkout 🔁
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #v5.0.0

- name: Set up Python ${{ matrix.python-version }} 🐍
uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 #v4.7.1
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c #v6.0.0
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
steps:
- name: Checkout 🔁
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #v5.0.0

- name: Set up Python ${{ matrix.python-version }} 🐍
uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 #v4.7.1
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c #v6.0.0
with:
python-version: ${{ matrix.python-version }}

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ router = SpecRouter(specs, validators=[MyValidator])

You will need:

- Python 3.9+ (tested on 3.9 - 3.13)
- Python 3.10+ (tested on 3.10 - 3.13)
- [pre-commit](https://pre-commit.com/#install)

Before working on the project, make sure you run:
Expand Down
2 changes: 1 addition & 1 deletion openapi_to_fastapi/model_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def generate_model_from_schema(
base_class="pydantic.BaseModel",
custom_template_dir=None,
extra_template_data=None,
target_python_version=PythonVersion.PY_39,
target_python_version=PythonVersion.PY_310,
dump_resolve_reference_action=None,
extra_fields="forbid" if strict_validation else None,
strict_types=strict_types,
Expand Down
329 changes: 180 additions & 149 deletions poetry.lock

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "openapi-to-fastapi"
version = "0.21.0"
version = "0.22.0"
description = "Create FastAPI routes from OpenAPI spec"
authors = ["IOXIO Ltd"]
license = "BSD-3-Clause"
Expand All @@ -14,12 +14,12 @@ packages = [
openapi-validator = "openapi_to_fastapi.cli:cli_validate_specs"

[tool.poetry.dependencies]
python = "^3.9"
datamodel-code-generator = "^0.33.0"
fastapi = "^0.116.1"
click = "^8.1.8"
python = "^3.10"
datamodel-code-generator = "^0.35.0"
fastapi = "^0.121.1"
click = "^8.3.0"
coloredlogs = "^15.0.1"
pydantic = {version = "^2.11.7", extras = ["email"]}
pydantic = {version = "^2.12.4", extras = ["email"]}

[tool.poetry.group.dev.dependencies]
isort = "^5.13.2"
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ exclude = .venv,.git,.mypy_cache
[mypy]
warn_return_any = True
ignore_missing_imports = True
python_version = 3.9
python_version = 3.10