Development¶
This section covers development setup, testing, and contributing to TuFT.
Testing Guide
How to run tests on CPU and GPU, including persistence testing.
Setup Development Environment¶
Install uv if you haven’t already:
curl -LsSf https://astral.sh/uv/install.sh | shInstall dev dependencies:
uv sync --extra devSet up pre-commit hooks:
uv run pre-commit install
Linting and Type Checking¶
Run the linter:
uv run ruff check .
uv run ruff format .
Run the type checker:
uv run pyright
Code Style¶
Follow PEP 8 guidelines
Use type hints for all function signatures
Write docstrings for public APIs
Keep line length under 100 characters
Pull Request Process¶
Fork the repository
Create a feature branch
Make your changes
Run tests and linting
Submit a pull request with a clear description