From 46be7cabb84a0faf3758e918fca0246334ec9345 Mon Sep 17 00:00:00 2001 From: Timothy Farrell Date: Sun, 28 Dec 2025 12:09:53 -0600 Subject: [PATCH] Clean mypy run --- .vscode/tasks.json | 15 +++++++++++++++ app/__init__.py | 0 app/core/database.py | 4 ++-- 3 files changed, 17 insertions(+), 2 deletions(-) create mode 100644 .vscode/tasks.json create mode 100644 app/__init__.py diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..0a0c078 --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,15 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "Run Mypy", + "type": "shell", + "command": "uv run mypy .", + "problemMatcher": [ + "$python" + ] + } + ] +} \ No newline at end of file diff --git a/app/__init__.py b/app/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/app/core/database.py b/app/core/database.py index 2c67567..4ab6434 100644 --- a/app/core/database.py +++ b/app/core/database.py @@ -1,5 +1,5 @@ """Database configuration and connection management.""" -from typing import AsyncGenerator +from typing import Generator from sqlalchemy import create_engine, MetaData from sqlalchemy.ext.asyncio import AsyncSession, create_async_engine, async_sessionmaker from sqlalchemy.orm import DeclarativeBase, sessionmaker, Session @@ -25,7 +25,7 @@ engine = create_engine( SessionLocal = sessionmaker(autocommit=False, autoflush=False, bind=engine) -def get_db() -> AsyncGenerator[Session, None]: +def get_db() -> Generator[Session, None]: """Dependency to get database session.""" db = SessionLocal() try: