Contributing¶
Development setup¶
git clone https://github.com/zerotonin/thermostrife.git
cd thermostrife
pip install -e ".[climate,dev]"
For the ERA5 / 20CRv3 fallback tiers you will also need a Copernicus CDS API key — see Getting started.
Running the test suite¶
pytest
CI-matched run with coverage:
pytest --cov=thermostrife --cov-report=term
Linting¶
ruff check .
ruff check . --fix # apply safe fixes
Building the docs locally¶
pip install -r docs/requirements.txt
sphinx-build -b html docs/ docs/_build/html
xdg-open docs/_build/html/index.html
Commit conventions¶
Atomic commits, one logical change per commit.
Prefix |
Use for |
|---|---|
|
New feature in |
|
Bug fix in |
|
Restructure without behaviour change |
|
Documentation only |
|
Test additions or fixes |
|
Curated CSV updates (event additions, casualty revisions, weather citations) |
|
Continuous integration changes |
|
Tooling, dependencies, housekeeping |
data(...) is ThermoStrife-specific — the curated CSV is part of the
scientific contribution, and edits deserve clear commit provenance.
Pull request workflow¶
Fork and create a feature branch from
main.Run
pytestandruff check .locally.Open a PR against
main. Bothtestsanddocsworkflows must pass.CSV edits get the same review weight as code edits — please include a citation in the row’s
event_data_sourceortemp_data_source.