Skip to content

Development

Requires Python 3.11 or higher.

Setup

# Install dependencies (include optional backends for full test coverage)
uv pip install -e ".[dev,polars,pandas,sqlalchemy]"

Testing

# Run all tests
pytest

# Run with coverage report
pytest --cov=therismos --cov-report=html

# Run a specific test file
pytest tests/test_optimizer.py

Linting and Formatting

# Check for issues
ruff check therismos tests

# Apply fixes
ruff check --fix therismos tests

# Format code
ruff format therismos tests

Type Checking

mypy therismos

Full Check Suite

# Run all environments (tests on py311–py314, lint, type)
tox

Tox environments:

Environment Purpose
py311, py312, py313, py314 Test suite on each Python version
lint ruff check and format check
type mypy strict type checking
format ruff format and fix (not in default run)