Contributing to imdtrack#
Thanks for helping! Bug reports, fixes, and features are all welcome via issues and pull requests.
Development setup (uv)#
uv is the fastest way to get a dev environment.
uv sync installs the exact, locked dependencies from uv.lock into .venv:
uv sync --extra dev --extra plot --extra docs # everything, reproducibly
(Plain pip works too: pip install -e ".[dev]".) The version is derived from
git tags by hatch-vcs, so there’s no
__version__ to edit. If you change dependencies in pyproject.toml, refresh
the lock with uv lock and commit it.
Checks#
uv run pytest # tests (cartopy plot tests skip without cartopy)
uv run black . && uv run ruff check . # format + lint
Install the pre-commit hooks so these run automatically:
uv pip install pre-commit
pre-commit install --hook-type pre-commit --hook-type pre-push
Workflow#
Never push to main directly. Create a branch, open a PR, and let CI (lint +
tests on Python 3.9–3.14 + docs build) go green before merging:
git switch -c my-change
# ... commit ...
git push -u origin my-change # then open a PR
Releases#
Releases are cut from a git tag — no source edit. Tag main and push:
git tag v0.2.6 && git push origin v0.2.6
That triggers the release workflow (build → TestPyPI → PyPI → GitHub Release →
Zenodo). The dataset in data/ also auto-updates monthly and cuts its own
patch release when IMD publishes new data.