Skip to content

Commit de4ccdb

Browse files
authored
Merge branch 'main' into patch-1
2 parents 26d5db6 + ea18162 commit de4ccdb

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

docs/release-notes.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
## Latest Changes
44

5+
* 🐛 Fix SQLAlchemy version 1.4.36 breaks SQLModel relationships (#315). PR [#322](https://github.com/tiangolo/sqlmodel/pull/322) by [@byrman](https://github.com/byrman).
56
* 👷 Add CI for Python 3.10. PR [#305](https://github.com/tiangolo/sqlmodel/pull/305) by [@tiangolo](https://github.com/tiangolo).
67
* 📝 Add Jina's QA Bot to the docs to help people that want to ask quick questions. PR [#263](https://github.com/tiangolo/sqlmodel/pull/263) by [@tiangolo](https://github.com/tiangolo).
78
* 👷 Upgrade Codecov GitHub Action. PR [#304](https://github.com/tiangolo/sqlmodel/pull/304) by [@tiangolo](https://github.com/tiangolo).

sqlmodel/main.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,7 @@ def __init__(
369369
relationship_to, *rel_args, **rel_kwargs
370370
)
371371
dict_used[rel_name] = rel_value
372+
setattr(cls, rel_name, rel_value) # Fix #315
372373
DeclarativeMeta.__init__(cls, classname, bases, dict_used, **kw)
373374
else:
374375
ModelMetaclass.__init__(cls, classname, bases, dict_, **kw)

0 commit comments

Comments
 (0)