python-no-type-checking-guard
Installation
SKILL.md
Python typing without TYPE_CHECKING
This skill defines hard rules and preferred patterns for writing typed Python
code without ever using from typing import TYPE_CHECKING or
if TYPE_CHECKING: blocks. It applies to all Python code the agent creates
or edits unless the user explicitly overrides this style for a specific file.
For detailed examples and design rationale, consult the bundled reference
references/python-module-design-without-type-checking.md.
Non‑negotiable rules
Follow these rules strictly unless the user explicitly instructs otherwise.
- Never import
TYPE_CHECKING.- Do not write
from typing import TYPE_CHECKING. - Do not rely on
typing.TYPE_CHECKINGor any alias of it. - Do not introduce
TYPE_CHECKING = Falseor similar "shadow" variables as an alternative.
- Do not write