Skip to content

Commit

Permalink
fix: Specify generic type for DateTimeUTC (#124)
Browse files Browse the repository at this point in the history
  • Loading branch information
wer153 committed Jan 31, 2024
1 parent 6420050 commit 0f40a1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions advanced_alchemy/types/datetime.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from __future__ import annotations

import datetime
from typing import TYPE_CHECKING
from typing import TYPE_CHECKING, Optional

from sqlalchemy import DateTime
from sqlalchemy.types import TypeDecorator
Expand All @@ -10,7 +10,7 @@
from sqlalchemy.engine import Dialect


class DateTimeUTC(TypeDecorator):
class DateTimeUTC(TypeDecorator[Optional[datetime.datetime]]):
"""Timezone Aware DateTime.
Ensure UTC is stored in the database and that TZ aware dates are returned for all dialects.
Expand Down

0 comments on commit 0f40a1c

Please sign in to comment.