BSK-0005 analyze

Missing class attribute type annotation

Every class attribute declared in the class body must have an explicit type annotation. Without one, Basilisk cannot verify assignments to the attribute and cannot produce accurate stub types.

Enum subclasses and Protocol subclasses are exempt: Enum members have metaclass-synthesised Literal... types, and Protocol attributes are interface specifications rather than concrete class variables.

Real basilisk check output

What you see when BSK-0005 fires on a minimal example:

basilisk check output reporting BSK-0005 — Missing class attribute type annotation

How to handle it

This Basilisk-specific rule is off by default. Enable its strictness tag when the policy fits your project, then configure its severity globally or per path in pyproject.toml.

Canonical URL: https://www.basilisk-python.dev/errors/BSK-0005