You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
1.5 KiB

<!-- crag:auto-start -->
# Cline Rules — fastapi
Generated from governance.md by crag. Regenerate with: `crag compile --target cline`
## About this project
(No description)
Stack: python
Runtimes: python
## Mandatory behavior
1. Read this file at the start of every session. Read `governance.md` for full context.
2. Run all mandatory quality gates before proposing a commit.
3. If a gate fails, attempt an automatic fix (lint/format) with bounded retry (max 2 attempts). If it still fails, escalate to the user.
4. Never modify files outside this repository.
5. Never run destructive system commands (rm -rf /, DROP TABLE, force-push to main, curl|bash).
6. Use conventional commits.
## Quality gates
Run these in order, stop on first MANDATORY failure:
- uv run mypy .
- uv run pytest
- python -m build
- python -m build --sdist
- uv run --no-sync bash scripts/test-cov.sh
- uv run --no-sync pytest tests/benchmarks --codspeed
- uv run coverage combine coverage
- uv run coverage html --title "Coverage for ${{ github.sha }}"
- uv run coverage report --fail-under=100
## Security
- No hardcoded secrets — grep for sk_live, AKIA, password= before commit
## Workflow
For every task:
1. Read the governance.md file first
2. Understand which files need to change
3. Make minimal, focused changes
4. Run all mandatory gates
5. Commit with a conventional commit message
## Tool context
This project uses **crag** — the governance engine for AI coding agents. https://www.npmjs.com/package/@whitehatd/crag
<!-- crag:auto-end -->