From fa63a0fc98ac6c1306ba8c303113709f97b430a0 Mon Sep 17 00:00:00 2001 From: Hugh Runyan Date: Wed, 9 Sep 2026 06:34:53 -0700 Subject: [PATCH] The README's test setup installs the way CI does MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Copilot spotted this on #61 and it went in unresolved. The Tests block told a contributor to run a bare `pip install -e .` right after installing the pinned lockfile — and `setup.py`'s `install_requires` comes from `requirements.in`, the abstract deps, so pip re-resolves what `requirements.txt` had just pinned. CI already gets this right and says why in a comment: # Editable, --no-deps: makes `import SWEET_python` resolve to this # checkout without re-resolving what requirements.txt just pinned So the README was the only place giving the advice CI's own comment warns against. It now matches, with the reason written down. The `pip install -e .` under Installation is deliberately left alone: that is the consumer path, it has no lockfile to protect, and it should resolve its dependencies. Co-Authored-By: Claude Opus 5 --- README.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 0155f1c..677eb01 100644 --- a/README.md +++ b/README.md @@ -15,10 +15,18 @@ The test suite lives in `tests/` and runs with pytest: ``` pip install -r requirements.txt "pytest>=8,<10" -pip install -e . +pip install --no-deps -e . pytest ``` +`--no-deps` on the editable install is the point of the two lines above it: +`setup.py`'s `install_requires` comes from `requirements.in`, the abstract deps, +so without it pip re-resolves what `requirements.txt` just pinned and the local +environment stops matching CI. The install step in +`.github/workflows/tests.yml` is the same three commands for the same reason. +(The `pip install -e .` in Installation above has no lockfile to protect and +should resolve its dependencies.) + Every test in the suite is hermetic — no database, no network, no environment variables — and the whole thing takes a few seconds.