Contributing¶
Development Setup¶
- Clone the repo.
- Install dependencies:
- Run tests:
Code Generation¶
The SDK is generated from the Riot Games OpenAPI spec. The generator cleans the output directory before writing, so stale files are automatically removed.
To regenerate:
# Fetch latest spec
python tools/manager.py
# Generate code (endpoints, models, client mixin)
python tools/generator/core.py
Generated files:
| File | Description |
|---|---|
src/riotskillissue/api/models.py |
Pydantic models for all API schemas |
src/riotskillissue/api/endpoints/*.py |
Endpoint classes for each API tag |
src/riotskillissue/api/client_mixin.py |
Mixin that wires endpoints into RiotClient |
Do not edit generated files
Files in src/riotskillissue/api/ are auto-generated. Edit the Jinja2 templates in tools/templates/ instead.
Templates¶
| Template | Generates |
|---|---|
tools/templates/models.py.j2 |
api/models.py |
tools/templates/endpoints.py.j2 |
api/endpoints/*.py |
tools/templates/client_mixin.py.j2 |
api/client_mixin.py |
Release Process¶
- Update
CHANGELOG.mdwith the new version. - Bump version in
pyproject.toml. - Tag: Create a new GitHub release with a tag (e.g.,
v1.0.0). - Publish: The GitHub Action
.github/workflows/publish.ymlwill automatically build and push to PyPI using Trusted Publishing. - Verify: Check PyPI project page.