Thank you for your interest in contributing!
- Fork and clone the repository
- Install:
uv sync --group dev - Install hooks:
uv run lefthook install - Test:
uv run pytest tests/src/e2e/ -n2 --dist loadscope -v(requires Docker) - Make changes and commit
- Open Pull Request
See tests/README.md.
Setup:
cp .env.example .env # Edit with your HA details
uv sync --group dev
uv run lefthook install # Install git hooksCode quality:
uv run ruff format src/ tests/ # Format
uv run ruff check --fix src/ tests/ # Lint
uv run mypy src/ # Type check
uv run ast-grep scan # AST lint (error handling patterns)On every commit, hooks run ruff check --fix (lint), ast-grep scan (AST lint), mypy (type check), and unit tests in parallel via lefthook. The Ruff Lint and AST Lint CI jobs also enforce these on pull requests; Ruff Lint additionally runs ruff format --check on changed Python files.
If you had pre-commit installed from a previous checkout:
uv run pre-commit uninstall
uv sync --group dev
uv run lefthook install --reset-hooks-path- Code: Follow existing patterns, add type hints, test new features
- Docs: Update README.md for user-facing changes
- PRs: Use the template, ensure tests pass
If a maintainer requests changes or an update on a PR and there is no response or activity from the author for 7 days, a maintainer may, at their discretion, take over the PR (push to it or supersede it) or close it.
- An automated reminder is posted on the PR after 4 and 6 days without a response.
- Any activity from the author (a comment is enough) resets the clock.
- This is a guideline, not a hard rule — maintainers may leave a PR open longer when the situation warrants it.
Thank you for contributing! 🎉