We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 05d32da commit a05a685Copy full SHA for a05a685
sqlmodel/_compat.py
@@ -212,6 +212,11 @@ def _is_type_alias_type_instance(annotation: Any) -> bool:
212
if in_typing_extensions:
213
check_type.append(typing_extensions.TypeAliasType)
214
215
+ if sys.version_info[:2] == (3, 10):
216
+ if type(annotation) is types.GenericAlias:
217
+ # In Python 3.10, TypeAliasType instances are of type GenericAlias
218
+ return False
219
+
220
return check_type and isinstance(annotation, tuple(check_type))
221
222
def get_sa_type_from_type_annotation(annotation: Any) -> Any:
0 commit comments