Drop Python 3.9 support

This commit is contained in:
François Voron
2025-10-25 08:19:03 +02:00
parent ae5ff025ef
commit fcf9a2041a
33 changed files with 224 additions and 234 deletions

View File

@ -1,5 +1,5 @@
from datetime import datetime
from typing import Any, Generic, Optional, Protocol
from typing import Any, Generic, Protocol
from fastapi_users.authentication.strategy.db.models import AP
@ -8,8 +8,8 @@ class AccessTokenDatabase(Protocol, Generic[AP]):
"""Protocol for retrieving, creating and updating access tokens from a database."""
async def get_by_token(
self, token: str, max_age: Optional[datetime] = None
) -> Optional[AP]:
self, token: str, max_age: datetime | None = None
) -> AP | None:
"""Get a single access token by token."""
... # pragma: no cover