Linting Exception Conditions
Resolve linting errors — do not suppress them. Linting errors signal architectural issues, not noise.
Acceptable Exceptions
Fix linting issues unless code falls into these categories:
- Vendored code — third-party code copied without modification (not authored by model)
- What-not-to-do examples — intentionally incorrect code for educational/negative test cases
- Historic Python version pinning — code for Python <3.11 where modern syntax unavailable (currently no code in this category — verify before assuming)
- Python derivatives — CircuitPython, MicroPython, or implementations with different syntax/missing stdlib modules
For these exceptions: update linting config files (pyproject.toml, .vscode/settings.json) to exclude the files. Do not use inline comments (# noqa, # type: ignore).
Unacceptable Exceptions (MUST fix or escalate)
If NONE of the above apply:
- Fix linting smell using
/hollistic-linting:hollistic-linting Skill (exact methodology for addressing linting issues)
- If unable to fix, document specific blocker
- Adding
# type: ignore or # noqa requires explicit user approval
Rule Codes That MUST Always Be Fixed (never suppress)
- BLE001 (blind-except): Replace
except Exception with specific exception types
- D103 (missing-docstring-in-public-function): Add docstrings to public functions
- TRY300 (try-consider-else): Restructure try/except/else blocks properly
Per-File Exceptions in pyproject.toml (acceptable)
**/scripts/**: T201 (print), S (security), DOC, ANN401, PLR0911, PLR0917, PLC0415
**/tests/**: S, D, E501, ANN, DOC, PLC, SLF, PLR, EXE, N, T
**/assets/**: PLC0415, DOC
typings/**: N, ANN, A
Touched Files Must Be Clean: When files are modified/moved/renamed, all linting issues MUST be resolved before committing. Touching a file means taking responsibility for its quality.
SOURCE: User policy established in conversation (2025-01-15)
1---2name: linting-exception-conditions3description: Resolve linting errors — do not suppress them. Linting errors signal architectural issues, not noise.4---56# Linting Exception Conditions78Resolve linting errors — do not suppress them. Linting errors signal architectural issues, not noise.910## Acceptable Exceptions1112Fix linting issues unless code falls into these categories:13141. **Vendored code** — third-party code copied without modification (not authored by model)152. **What-not-to-do examples** — intentionally incorrect code for educational/negative test cases163. **Historic Python version pinning** — code for Python <3.11 where modern syntax unavailable (currently no code in this category — verify before assuming)174. **Python derivatives** — CircuitPython, MicroPython, or implementations with different syntax/missing stdlib modules1819For these exceptions: update linting config files (`pyproject.toml`, `.vscode/settings.json`) to exclude the files. Do not use inline comments (`# noqa`, `# type: ignore`).2021## Unacceptable Exceptions (MUST fix or escalate)2223If NONE of the above apply:24251. Fix linting smell using `/hollistic-linting:hollistic-linting` Skill (exact methodology for addressing linting issues)262. If unable to fix, document specific blocker273. Adding `# type: ignore` or `# noqa` requires explicit user approval2829## Rule Codes That MUST Always Be Fixed (never suppress)3031- BLE001 (blind-except): Replace `except Exception` with specific exception types32- D103 (missing-docstring-in-public-function): Add docstrings to public functions33- TRY300 (try-consider-else): Restructure try/except/else blocks properly3435## Per-File Exceptions in pyproject.toml (acceptable)3637- `**/scripts/**`: T201 (print), S (security), DOC, ANN401, PLR0911, PLR0917, PLC041538- `**/tests/**`: S, D, E501, ANN, DOC, PLC, SLF, PLR, EXE, N, T39- `**/assets/**`: PLC0415, DOC40- `typings/**`: N, ANN, A4142**Touched Files Must Be Clean**: When files are modified/moved/renamed, all linting issues MUST be resolved before committing. Touching a file means taking responsibility for its quality.4344SOURCE: User policy established in conversation (2025-01-15)