13 lines
296 B
Python
13 lines
296 B
Python
|
|
from datetime import datetime, timezone
|
||
|
|
|
||
|
|
from sqlalchemy.orm import DeclarativeBase
|
||
|
|
|
||
|
|
|
||
|
|
def utcnow() -> datetime:
|
||
|
|
"""Naive UTC timestamp — all datetimes are stored as UTC in MySQL DATETIME."""
|
||
|
|
return datetime.now(timezone.utc).replace(tzinfo=None)
|
||
|
|
|
||
|
|
|
||
|
|
class Base(DeclarativeBase):
|
||
|
|
pass
|