diff --git a/backend/app/api/api_v1/endpoints/bookmarks.py b/backend/app/api/api_v1/endpoints/bookmarks.py index 74a6a464..bce536a2 100644 --- a/backend/app/api/api_v1/endpoints/bookmarks.py +++ b/backend/app/api/api_v1/endpoints/bookmarks.py @@ -4,7 +4,6 @@ from app import crud, schemas from app.api import deps from app.api.deps import current_active_superuser, current_active_user -from app.core import auth from app.models.user import User router = APIRouter() diff --git a/backend/app/api/api_v1/endpoints/caseinfo.py b/backend/app/api/api_v1/endpoints/caseinfo.py index 51751432..a28d7089 100644 --- a/backend/app/api/api_v1/endpoints/caseinfo.py +++ b/backend/app/api/api_v1/endpoints/caseinfo.py @@ -4,7 +4,6 @@ from app import crud, schemas from app.api import deps from app.api.deps import current_active_superuser, current_active_user -from app.core import auth from app.models.user import User router = APIRouter() diff --git a/backend/app/api/api_v1/endpoints/utils.py b/backend/app/api/api_v1/endpoints/utils.py index c4cbed0a..8bc8c132 100644 --- a/backend/app/api/api_v1/endpoints/utils.py +++ b/backend/app/api/api_v1/endpoints/utils.py @@ -3,11 +3,9 @@ from fastapi import APIRouter, Depends from pydantic.networks import EmailStr -from app import models, schemas -from app.api import deps +from app import schemas from app.api.deps import current_active_superuser from app.app.utils import send_test_email -from app.core import auth router = APIRouter() diff --git a/backend/app/api/deps.py b/backend/app/api/deps.py index f1cff626..b19e72b9 100644 --- a/backend/app/api/deps.py +++ b/backend/app/api/deps.py @@ -1,6 +1,4 @@ -from typing import AsyncGenerator, AsyncIterator - -from sqlalchemy.ext.asyncio import AsyncSession, async_sessionmaker +from typing import AsyncIterator from app.core import auth from app.db.session import SessionLocal, engine diff --git a/backend/app/app/utils.py b/backend/app/app/utils.py index 9cc4ee70..2e42e446 100644 --- a/backend/app/app/utils.py +++ b/backend/app/app/utils.py @@ -1,7 +1,6 @@ import logging -from datetime import datetime, timedelta from pathlib import Path -from typing import Any, Dict, Optional +from typing import Any, Dict import emails from emails.template import JinjaTemplate diff --git a/backend/app/core/auth.py b/backend/app/core/auth.py index 0991fbdd..5977bba9 100644 --- a/backend/app/core/auth.py +++ b/backend/app/core/auth.py @@ -1,9 +1,9 @@ import uuid -from typing import Any, Optional +from typing import Optional import redis.asyncio from fastapi import Depends, Request, Response -from fastapi_users import BaseUserManager, FastAPIUsers, UUIDIDMixin, models +from fastapi_users import BaseUserManager, FastAPIUsers, UUIDIDMixin from fastapi_users.authentication import ( AuthenticationBackend, BearerTransport, diff --git a/backend/app/core/config.py b/backend/app/core/config.py index bc9f75e8..2e7aa7b4 100644 --- a/backend/app/core/config.py +++ b/backend/app/core/config.py @@ -1,7 +1,6 @@ import logging import os import secrets -import typing from typing import Any from pydantic import AnyHttpUrl, EmailStr, HttpUrl, PostgresDsn, field_validator diff --git a/backend/app/core/deps.py b/backend/app/core/deps.py index d515d918..e55fb48f 100644 --- a/backend/app/core/deps.py +++ b/backend/app/core/deps.py @@ -1,9 +1,8 @@ -from typing import AsyncGenerator, AsyncIterator +from typing import AsyncGenerator from sqlalchemy.ext.asyncio import AsyncSession, async_sessionmaker -from app.core import auth -from app.db.session import SessionLocal, engine +from app.db.session import engine async_session_maker = async_sessionmaker(engine, expire_on_commit=False) diff --git a/backend/app/main.py b/backend/app/main.py index f2fce8cb..4e7d5ada 100644 --- a/backend/app/main.py +++ b/backend/app/main.py @@ -1,8 +1,7 @@ import logging import pathlib -from fastapi import FastAPI, Request -from fastapi.staticfiles import StaticFiles +from fastapi import FastAPI from starlette.middleware.cors import CORSMiddleware from starlette.responses import FileResponse diff --git a/backend/tests/api/api_v1/test_utils.py b/backend/tests/api/api_v1/test_utils.py index 483fcc53..5aaf8fb9 100644 --- a/backend/tests/api/api_v1/test_utils.py +++ b/backend/tests/api/api_v1/test_utils.py @@ -1,10 +1,7 @@ -import uuid - import pytest from fastapi.testclient import TestClient from sqlalchemy.ext.asyncio import AsyncSession -from app.app.utils import send_test_email from app.core.config import settings from app.models.user import User diff --git a/backend/tests/api/internal/test_proxy.py b/backend/tests/api/internal/test_proxy.py index 4ccb72a1..8de728cf 100644 --- a/backend/tests/api/internal/test_proxy.py +++ b/backend/tests/api/internal/test_proxy.py @@ -3,7 +3,6 @@ from fastapi.testclient import TestClient from pytest_httpx._httpx_mock import HTTPXMock -from app.api.internal.endpoints.remote import default_acmg_rating from app.core.config import settings #: Host name to use for the mocked backend. diff --git a/backend/tests/app/test_utils.py b/backend/tests/app/test_utils.py index 6fa70e6f..1a795b0a 100644 --- a/backend/tests/app/test_utils.py +++ b/backend/tests/app/test_utils.py @@ -1,4 +1,4 @@ -from unittest.mock import MagicMock, mock_open, patch +from unittest.mock import MagicMock, mock_open import pytest from starlette.requests import Request