Files
computer-playbook/cli/contributing/mirror/model.py
T
kevinveenbirkenbachandClaude Opus 5 7fee974c7f fix(cli): stop declaring a re-exported class in __all__
autodoc documents whatever __all__ lists, including a name the module only
imported, so sphinx found two targets for every annotation: nine for
ImageRef and one for DevInventorySpec.

mirror/model is a five-line shim whose whole purpose is the local name, so
it drops __all__ entirely. The inventory package keeps its own, which also
declares private helpers, and loses only that one entry; the reason sits in
the module docstring so nobody re-adds it innocently.

Both names stay importable from their packages, because the import binds
them regardless of __all__. Every importer in the repository was enumerated
and none uses a wildcard.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-25 19:32:49 +02:00

11 lines
363 B
Python

"""Local name for the image reference the mirror commands pass around.
No ``__all__``: declaring the re-exported name makes autodoc document the
class here as well as where it is defined, and sphinx then finds two targets
for every ``ImageRef`` annotation.
"""
from __future__ import annotations
from utils.docker.image.discovery import ImageRef # noqa: F401