STRUCT001infoFree tier

multiple-classes-per-file

Multiple classes defined in a single file.

Applies to: Python

Why this matters

Having multiple classes in one file makes code harder to find and maintain. Each class should live in its own file, named after the class. This makes imports clearer and helps AI assistants understand your codebase structure.

Catch it before it ships

pip install stablestack # or: npx stablestackstablestack # scans your project, STRUCT001 includedstablestack explain STRUCT001

False positive in your codebase? Suppress a single line with # noqa: STRUCT001