Skip to content

Commit 1150365

Browse files
authored
Merge branch 'main' into pre-commit-ci-update-config
2 parents c28f707 + 8d212e8 commit 1150365

File tree

5 files changed

+23
-8
lines changed

5 files changed

+23
-8
lines changed

.github/workflows/test.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ jobs:
3232
- "3.10"
3333
- "3.11"
3434
- "3.12"
35+
- "3.13"
3536
pydantic-version:
3637
- pydantic-v1
3738
- pydantic-v2
@@ -71,7 +72,10 @@ jobs:
7172
run: uv pip install --upgrade "pydantic>=1.10.0,<2.0.0"
7273
- name: Install Pydantic v2
7374
if: matrix.pydantic-version == 'pydantic-v2'
74-
run: uv pip install --upgrade "pydantic>=2.0.2,<3.0.0" "typing-extensions==4.6.1"
75+
run: uv pip install --upgrade "pydantic>=2.0.2,<3.0.0"
76+
- name: Pin typing-extensions for Python 3.7
77+
if: matrix.python-version == '3.7'
78+
run: uv pip install --upgrade "typing-extensions==4.6.1"
7579
- name: Lint
7680
# Do not run on Python 3.7 as mypy behaves differently
7781
if: matrix.python-version != '3.7' && matrix.pydantic-version == 'pydantic-v2'
@@ -97,7 +101,7 @@ jobs:
97101
- uses: actions/checkout@v4
98102
- uses: actions/setup-python@v5
99103
with:
100-
python-version: '3.12'
104+
python-version: '3.13'
101105
- name: Setup uv
102106
uses: astral-sh/setup-uv@v5
103107
with:

docs/release-notes.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22

33
## Latest Changes
44

5+
### Upgrades
6+
7+
* ⬆️ Add support for Python 3.13. PR [#1289](https://github.com/fastapi/sqlmodel/pull/1289) by [@svlandeg](https://github.com/svlandeg).
8+
9+
### Internal
10+
11+
* ⬆ Bump ruff from 0.6.2 to 0.9.6. PR [#1294](https://github.com/fastapi/sqlmodel/pull/1294) by [@dependabot[bot]](https://github.com/apps/dependabot).
12+
513
## 0.0.23
614

715
### Fixes

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ classifiers = [
2626
"Programming Language :: Python :: 3.10",
2727
"Programming Language :: Python :: 3.11",
2828
"Programming Language :: Python :: 3.12",
29+
"Programming Language :: Python :: 3.13",
2930
"Topic :: Database",
3031
"Topic :: Database :: Database Engines/Servers",
3132
"Topic :: Internet",

requirements-tests.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,15 @@
33
pytest >=7.0.1,<8.0.0
44
coverage[toml] >=6.2,<8.0
55
mypy ==1.4.1
6-
ruff ==0.6.2
6+
ruff ==0.9.6
77
# For FastAPI tests
88
fastapi >=0.103.2
99
httpx ==0.24.1
1010
# TODO: upgrade when deprecating Python 3.7
11-
dirty-equals ==0.6.0
11+
dirty-equals ==0.6.0; python_version < "3.8"
12+
dirty-equals ==0.9.0; python_version >= "3.8"
1213
jinja2 ==3.1.4
1314
# Pin typing-extensions until Python 3.8 is deprecated or the issue with dirty-equals
1415
# is fixed, maybe fixed after dropping Python 3.7 and upgrading dirty-equals
15-
typing-extensions ==4.6.1
16+
typing-extensions ==4.6.1; python_version < "3.8"
17+
typing-extensions ==4.12.2; python_version >= "3.8"

sqlmodel/main.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,8 @@
9393
IncEx: TypeAlias = Union[
9494
Set[int],
9595
Set[str],
96-
Mapping[int, Union["IncEx", Literal[True]]],
97-
Mapping[str, Union["IncEx", Literal[True]]],
96+
Mapping[int, Union["IncEx", bool]],
97+
Mapping[str, Union["IncEx", bool]],
9898
]
9999
OnDeleteType = Literal["CASCADE", "SET NULL", "RESTRICT"]
100100

@@ -477,7 +477,7 @@ def Relationship(
477477
class SQLModelMetaclass(ModelMetaclass, DeclarativeMeta):
478478
__sqlmodel_relationships__: Dict[str, RelationshipInfo]
479479
model_config: SQLModelConfig
480-
model_fields: Dict[str, FieldInfo]
480+
model_fields: Dict[str, FieldInfo] # type: ignore[assignment]
481481
__config__: Type[SQLModelConfig]
482482
__fields__: Dict[str, ModelField] # type: ignore[assignment]
483483

0 commit comments

Comments
 (0)