Skip to content

Commit 0a8f3de

Browse files
fix: apply ruff formating
1 parent 2f7f91f commit 0a8f3de

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

backend/src/dependencies/auth0.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
from functools import lru_cache
12
from typing import Annotated, Any
23

34
from fastapi import Depends, HTTPException, Request
@@ -9,15 +10,13 @@
910
from src.users.auth0 import get_or_create_user_from_auth0, get_user_by_auth0_id
1011
from src.users.models import User
1112

12-
from functools import lru_cache
13-
1413
security = HTTPBearer()
1514

1615

1716
# Initialize Auth0Service
1817
# This is a singleton instance of Auth0Service
1918
# to be reused across requests.
20-
@lru_cache()
19+
@lru_cache
2120
def get_auth0_service() -> Auth0Service:
2221
"""
2322
Provides a singleton Auth0Service instance using lru_cache.
@@ -50,7 +49,6 @@ async def get_current_user_claims(
5049
async def get_current_user_info(
5150
request: Request,
5251
token: Annotated[str, Depends(get_token_from_header)],
53-
claims: Annotated[dict[str, Any], Depends(get_current_user_claims)],
5452
auth_service: Annotated[Auth0Service, Depends(get_auth0_service)],
5553
) -> UserInfo:
5654
"""

backend/src/services/auth0.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
from typing import Any, TypedDict
21
import logging
2+
from typing import Any, TypedDict
33

4+
import httpx
45
from authlib.integrations.starlette_client import OAuth
56
from authlib.jose import jwt
67
from fastapi import HTTPException, Request
78
from starlette.responses import RedirectResponse
8-
import httpx
99

1010
from src.core.config import settings
1111

0 commit comments

Comments
 (0)