← Back

allchain

Python __all__ chain validator and pre-commit hook for enforcing clean public APIs.

Python AST

allchain validates that Python packages correctly chain their __all__ exports from submodules up to the package root. Ruff doesn’t cover this — it checks that __all__ entries exist, but not that they’re consistent across a package hierarchy. Available as a standalone CLI tool and a pre-commit hook.