Code hygiene, quality gates, and pre-commit workflows. Use for linting, type checking, testing, and fixing errors.
Runs linting, type checking, and tests using ruff, mypy, and pytest. Use before commits to catch errors and maintain code quality gates.
/plugin marketplace add Shakes-tzd/htmlgraph/plugin install htmlgraph@htmlgraphThis skill inherits all available tools. When active, it can use any tool Claude has access to.
Use this skill for code hygiene, quality gates, and pre-commit workflows.
Trigger keywords: code quality, lint, mypy, ruff, pytest, pre-commit, type checking, clean code, fix errors
# Before EVERY commit:
uv run ruff check --fix # Lint + autofix
uv run ruff format # Format code
uv run mypy src/ # Type checking
uv run pytest # Run tests
# Only commit when ALL checks pass
git commit -m "..."
CRITICAL: Fix ALL errors with every commit, regardless of when introduced.
The deployment script (deploy-all.sh) blocks on:
This is intentional - maintain quality gates.
# Check for issues
uv run ruff check
# Check and auto-fix
uv run ruff check --fix
# Format code
uv run ruff format
# Check specific files
uv run ruff check src/htmlgraph/models.py
# Check all source
uv run mypy src/
# Check specific module
uv run mypy src/htmlgraph/sdk.py
# Ignore missing imports
uv run mypy src/ --ignore-missing-imports
# Run all tests
uv run pytest
# Verbose output
uv run pytest -v
# Run specific test file
uv run pytest tests/test_sdk.py
# Run specific test
uv run pytest tests/test_sdk.py::test_feature_create
# Before (type error)
def get_user(id):
return db.query(id)
# After (typed)
def get_user(id: str) -> User | None:
return db.query(id)
# Before (unused import)
import os
import sys
x = 1
# After (clean)
x = 1
# Auto-fix all formatting
uv run ruff format
Track quality improvements:
from htmlgraph import SDK
sdk = SDK(agent='code-quality')
spike = sdk.spikes.create('Fix mypy errors in models.py') \
.set_findings("""
Fixed 3 type errors:
- Added return type to get_user()
- Fixed Optional annotation on config
- Added type hints to utility functions
""") \
.save()
Remember: Fixing errors immediately is faster than letting them accumulate.
Use when working with Payload CMS projects (payload.config.ts, collections, fields, hooks, access control, Payload API). Use when debugging validation errors, security issues, relationship queries, transactions, or hook behavior.
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.