From 159a9508e5d03a432276b3cb32fb714a091c58f3 Mon Sep 17 00:00:00 2001 From: Colin L Date: Wed, 29 Apr 2026 19:33:33 -0700 Subject: [PATCH] refactor: split requirements.txt into runtime and dev MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The single requirements.txt bundled pytest, black, isort, mypy, and httpx alongside the runtime deps. install.sh's `pip install -r requirements.txt` therefore pulled the dev toolchain into a runtime venv unnecessarily. Splits into: - requirements.txt — runtime only (fastapi, uvicorn, pydantic, python-dotenv, openai, tiktoken) - requirements-dev.txt — pulls in requirements.txt then adds pytest, pytest-asyncio, httpx, black, isort, mypy This matches the runtime/dev split already declared in pyproject.toml under [project.optional-dependencies].dev. install.sh's existing command (pip install -r requirements.txt) automatically picks up the slimmer runtime set with no script change required. Note: fastapi[standard] still pulls httpx in transitively (via TestClient deps), so the --selftest flag continues to work in a runtime-only install. Co-Authored-By: Claude Opus 4.7 (1M context) --- requirements-dev.txt | 7 +++++++ requirements.txt | 7 ------- 2 files changed, 7 insertions(+), 7 deletions(-) create mode 100644 requirements-dev.txt diff --git a/requirements-dev.txt b/requirements-dev.txt new file mode 100644 index 00000000..77777003 --- /dev/null +++ b/requirements-dev.txt @@ -0,0 +1,7 @@ +-r requirements.txt +pytest>=7.0.0 +pytest-asyncio>=0.21.0 +httpx>=0.25.0 +black>=23.0.0 +isort>=5.12.0 +mypy>=1.0.0 diff --git a/requirements.txt b/requirements.txt index e2a0efcd..6a41dd5e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,10 +4,3 @@ pydantic>=2.0.0 python-dotenv>=1.0.0 openai>=1.54.0 tiktoken>=0.7.0 -# Dev dependencies -pytest>=7.0.0 -pytest-asyncio>=0.21.0 -httpx>=0.25.0 -black>=23.0.0 -isort>=5.12.0 -mypy>=1.0.0 \ No newline at end of file