diff --git a/CLAUDE.md b/CLAUDE.md index 78f0316..521c75e 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -13,7 +13,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co pip install -e ".[dev]" # Run dev server -uvicorn app.main:app --reload +uvicorn app.application:app --reload # Run all tests pytest diff --git a/README.md b/README.md index a1e9fd1..83cce78 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ Python/FastAPI backend for duty scheduling at [US Basketball Amsterdam](https:// pip install -e ".[dev]" cp .env.example .env # set DATABASE_URL, ADMIN_PASSWORD, JWT_SECRET alembic upgrade head -uvicorn app.main:app --reload +uvicorn app.application:app --reload ``` API docs available at `http://localhost:8000/docs`. diff --git a/api/index.py b/api/index.py index dae8f9c..c05246a 100644 --- a/api/index.py +++ b/api/index.py @@ -1 +1 @@ -from app.main import app # noqa: F401 — Vercel looks for `app` at module level +from app.application import app # noqa: F401 — Vercel looks for `app` at module level diff --git a/app/main.py b/app/application.py similarity index 100% rename from app/main.py rename to app/application.py diff --git a/pyproject.toml b/pyproject.toml index 906514b..ed63d55 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,12 +13,12 @@ dependencies = [ "passlib[bcrypt]>=1.7", "pydantic-settings>=2.0", "python-dotenv>=1.0", + "httpx>=0.27", ] [project.optional-dependencies] dev = [ "pytest>=8.0", - "httpx>=0.27", "pytest-asyncio>=0.24", ] diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index c889323..0000000 --- a/requirements.txt +++ /dev/null @@ -1,10 +0,0 @@ -fastapi>=0.115 -uvicorn[standard]>=0.32 -sqlalchemy>=2.0 -alembic>=1.14 -psycopg2-binary>=2.9 -python-jose[cryptography]>=3.3 -passlib[bcrypt]>=1.7 -pydantic-settings>=2.0 -python-dotenv>=1.0 -httpx>=0.27 diff --git a/tests/conftest.py b/tests/conftest.py index 65b766e..1cf1ac7 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -10,7 +10,7 @@ from app.db.engine import Base from app.dependencies import get_db -from app.main import app +from app.application import app TEST_DATABASE_URL = "sqlite:///:memory:" diff --git a/vercel.json b/vercel.json index 33e6a33..f308795 100644 --- a/vercel.json +++ b/vercel.json @@ -2,10 +2,5 @@ "$schema": "https://openapi.vercel.sh/vercel.json", "rewrites": [ { "source": "/(.*)", "destination": "/api/index" } - ], - "functions": { - "api/index.py": { - "excludeFiles": "{tests/**,**/*.test.py,**/test_*.py}" - } - } + ] }