- Python 3.10+
- Modal CLI (
pip install modal) - A GitHub Personal Access Token with
Actionspermissions (for integration testing)
pip install -e ".[dev]"This installs runtime dependencies (modal, httpx, fastapi) and dev tools (pytest, pytest-asyncio, ruff).
Run the local dev server:
make serveDeploy to Modal:
make deploymake testTests use pytest with pytest-asyncio. The test suite mocks Modal and external HTTP calls, so no Modal credentials are needed to run tests locally.
Tests live in tests/test_app.py. Follow existing patterns:
- Use
_make_request()and_make_webhook_body()helpers for webhook tests - Use
_next_delivery_id()for unique delivery IDs (prevents dedup cache collisions) - Mock
app.modalviapatch("app.modal")for GPU tests - Mock
app._call_github_apifor GitHub API tests - Mark async tests with
@pytest.mark.asyncio
make lintUses ruff with rules: E, F, W, I. Line length: 120. Target: Python 3.10.
Use Conventional Commits:
feat:new featuresfix:bug fixesdocs:documentation changestest:test additions or changesrefactor:code restructuringchore:build, CI, or tooling changes
- Keep PRs focused on a single change
- Ensure
make testandmake lintpass before pushing - Add tests for any new functionality