No slash command · from python-dev
Python development quality standards. Applies when writing, reviewing, or committing Python code. Enforces coding style, line length, type annotations, linting (ruff), type checking (ty), and testing (pytest).
Ships in python-dev. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
These standards apply whenever you write, review, or commit Python code.
Target 88 characters per line. Hard limit is 92 (enforced by ruff).
This is critical — write concise lines from the start. Strategies:
Do NOT write lines over 88 characters and rely on the formatter to fix them.
All imports MUST be at the top of the file. Do NOT use inline or local imports inside functions/methods. The only exceptions are:
ImportErrorUse modern syntax — do not import from typing for built-in generics.
# Correct
def process(data: str | None) -> list[dict[str, int]]:
items: set[str] = set()
return []
# Incorrect — never do this
from typing import Optional, List, Dict, Set
def process(data: Optional[str]) -> List[Dict[str, int]]:
items: Set[str] = set()
return []
Remove unused typing imports when converting to modern syntax.
.py files on saveUse Conventional Commits format. Every commit subject must start with a type prefix.
type: short imperative description
| Prefix | Use for |
|---|---|
feat: | New features or functionality |
fix: | Bug fixes |
chore: | Maintenance, deps, config, CI |
refactor: | Code changes that don't fix bugs or add features |
test: | Adding or updating tests |
docs: | Documentation only |
feat(auth): add token refresh is fine, feat: add token refresh is also finefix: handle null user in session check
The middleware assumed user was always set after auth,
but expired tokens produce a null user object.
When preparing to commit, run these checks in order. Only commit if ALL pass.
1. ruff format .
2. ruff check . --fix
3. ruff check .
4. deptry .
5. ty check
6. pytest -v --timeout=180
7. Commit
This project uses uv as its package manager. Always use uv to install or remove packages. Never use pip install or pip uninstall — they bypass the lockfile and can corrupt the environment.
uv add <package> # add a dependency
uv remove <package> # remove a dependency
uv sync # sync lockfile to environment
uv run <command> # run inside the virtual environment
uv run pytest # example: run tests
| Tool | Commands |
|---|---|
| ruff | ruff format . · ruff check . · ruff check . --fix |
| deptry | deptry . — find unused, missing, and transitive dependencies |
| ty | ty check · ty check <file> |
| uv | uv add <pkg> · uv sync · uv run <cmd> |
| pytest | pytest · pytest tests/test_file.py · pytest -v |
What SKILL.md sets; muted values are Claude Code's defaults
Generated from the plugin's indexed repository (vino9net/claude-python-skill) — no native marketplace selected
npx claudepluginhub p/vino9net-python-dev4 skills in this plugin
/permission-reviewReview the permission_guard.py hook log (path from $CLAUDE_HOOK_LOG) to find Bash commands that triggered permission prompts over a time window, then recommend updates to .claude/settings.json, .claude/settings.local.json, and .claude/scripts/permission_guard.py that would reduce future prompts. Triggers: "review permissions", "permission audit", "which commands keep prompting me", "/permission-review".
/pytestRun the project test suite and report results. Use before commits or after completing a feature to check for regressions.
/scaffoldScaffold new Python projects or add components to existing ones. Triggers: "new python project", "scaffold", "add API/CLI to project", "init project", "create project skeleton", "update project dependencies". Also use when asked to add FastAPI, Flask, Django, or other components to an existing Python project.
Other plugins' skills for the same job