Skip to content

Commit 40af690

Browse files
committed
Fix type hinting for relationship annotations in SQLModelMetaclass
1 parent 7c1919e commit 40af690

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sqlmodel/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -629,7 +629,7 @@ def __init__(
629629
ann = raw_ann.__args__[0]
630630
if origin is Annotated:
631631
ann = get_args(raw_ann)[0]
632-
cls.__annotations__[rel_name] = Mapped[ann]
632+
cls.__annotations__[rel_name] = Mapped[ann] # type: ignore[valid-type]
633633
else:
634634
ann = raw_ann
635635
# Plain forward references, for models not yet defined, are not

0 commit comments

Comments
 (0)