Skip to content

Commit 31d84e1

Browse files
committed
chore: clarify dependency requirement scopes
1 parent 8150eb3 commit 31d84e1

13 files changed

Lines changed: 125 additions & 102 deletions

.github/workflows/benchmark.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
run: |
2828
python -m pip install --upgrade pip
2929
pip install -e ".[nlp]"
30-
pip install -r requirements-dev.txt
30+
pip install -r requirements-benchmark.txt
3131
# Verify pytest-benchmark is installed and working
3232
python -c "import pytest_benchmark; print('pytest-benchmark version:', pytest_benchmark.__version__)"
3333
python -m pytest --version

.github/workflows/ci.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,26 +47,25 @@ jobs:
4747
python-version: ${{ matrix.python-version }}
4848
cache: "pip"
4949

50-
- name: Install base tooling
50+
- name: Upgrade pip
5151
run: |
5252
python -m pip install --upgrade pip
53-
pip install pytest pytest-cov coverage
5453
5554
- name: Install dependencies (core)
5655
if: matrix.install-profile == 'core'
5756
run: |
58-
pip install -e ".[dev,cli]"
57+
pip install -e ".[test,cli]" -r requirements-test.txt
5958
6059
- name: Install dependencies (nlp)
6160
if: matrix.install-profile == 'nlp'
6261
run: |
63-
pip install -e ".[dev,cli,nlp]"
62+
pip install -e ".[test,cli,nlp]" -r requirements-test.txt
6463
python -m spacy download en_core_web_sm
6564
6665
- name: Install dependencies (nlp-advanced)
6766
if: matrix.install-profile == 'nlp-advanced'
6867
run: |
69-
pip install -e ".[dev,cli,nlp,nlp-advanced]"
68+
pip install -e ".[test,cli,nlp,nlp-advanced]" -r requirements-test.txt
7069
python -m spacy download en_core_web_sm
7170
7271
- name: Run tests (core)

.github/workflows/release.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,8 @@ jobs:
126126
- name: Install dependencies
127127
run: |
128128
python -m pip install --upgrade pip
129-
pip install -e ".[all,dev]"
130-
pip install -r requirements-dev.txt
129+
pip install -e ".[all,test]"
130+
pip install -r requirements-test.txt
131131
pip install https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-3.7.1/en_core_web_sm-3.7.1.tar.gz
132132
133133
- name: Run tests with segfault protection
@@ -158,8 +158,7 @@ jobs:
158158
- name: Install core + CLI dependencies
159159
run: |
160160
python -m pip install --upgrade pip
161-
pip install pytest pytest-cov coverage
162-
pip install -e ".[dev,cli]"
161+
pip install -e ".[test,cli]" -r requirements-test.txt
163162
164163
- name: Run Python 3.13 core + CLI tests
165164
run: |

CONTRIBUTING.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,13 @@ python -m pip install --upgrade pip
3636
pip install -e ".[dev,cli]"
3737
```
3838

39+
For pinned local tooling, install the development requirements after the editable
40+
package install:
41+
42+
```bash
43+
pip install -r requirements-dev.txt
44+
```
45+
3946
For optional NLP or OCR work, install the relevant extras:
4047

4148
```bash

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,5 +162,6 @@ cd datafog-python
162162
python -m venv .venv
163163
source .venv/bin/activate # Windows: .venv\Scripts\activate
164164
pip install -e ".[all,dev]"
165+
pip install -r requirements-dev.txt
165166
pytest tests/
166167
```

justfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ default:
2121
# Set up the development environment
2222
setup:
2323
python -m venv {{venv_dir}}
24-
{{pip}} install -e ".[dev]"
25-
{{pip}} install isort black blacken-docs flake8 tox coverage pytest pytest-cov
24+
{{pip}} install -e ".[dev,cli]"
25+
{{pip}} install -r requirements-dev.txt
2626

2727
# Format the code
2828
format:
@@ -79,4 +79,4 @@ upload: clean
7979
publish: tag upload
8080

8181
# Run all checks (format, lint, test, coverage)
82-
check: format lint test coverage
82+
check: format lint test coverage

requirements-benchmark.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Benchmark-only dependencies.
2+
-r requirements-test.txt
3+
pytest-benchmark==4.0.0

requirements-dev.txt

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
1-
# Include the base requirements
2-
-r requirements.txt
1+
# Local development tooling.
2+
#
3+
# Install the package itself with the extras you need, for example:
4+
# pip install -e ".[dev,cli]"
5+
# pip install -e ".[all,dev]"
6+
-r requirements-test.txt
7+
-r requirements-docs.txt
38

4-
# Development and testing dependencies
59
just==0.8.162
610
isort==5.13.2
711
black==26.3.1
@@ -14,4 +18,4 @@ pytest-benchmark==4.0.0
1418
mypy==1.9.0
1519
autoflake==2.2.1
1620
pre-commit==3.7.0
17-
ruff==0.3.4
21+
ruff==0.3.4

requirements-docs.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Documentation-only dependencies.
2+
sphinx==7.2.6

requirements-test.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Test-only dependencies.
2+
pytest==9.0.3
3+
pytest-asyncio==1.3.0
4+
pytest-cov==7.1.0

0 commit comments

Comments
 (0)