diff --git a/fastapi_users/db/sqlalchemy.py b/fastapi_users/db/sqlalchemy.py index fd832436..e5ec0270 100644 --- a/fastapi_users/db/sqlalchemy.py +++ b/fastapi_users/db/sqlalchemy.py @@ -18,8 +18,10 @@ class GUID(TypeDecorator): # pragma: no cover Uses PostgreSQL's UUID type, otherwise uses CHAR(36), storing as regular strings. """ + class UUIDChar(CHAR): + python_type = UUID4 - impl = CHAR + impl = UUIDChar def load_dialect_impl(self, dialect): if dialect.name == "postgresql":