1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2026-02-04 07:51:50 +00:00

Move IndexType alias inside TYPE_CHECKING block

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Jose Drowne 2026-01-31 01:12:50 -05:00
parent 1ec4538a80
commit fe89b60b80

View file

@ -304,8 +304,9 @@ class TomlFileError(Exception):
pass
# Type alias for array-of-tables index (int for position, "append" for new entry, None for default)
IndexType = t.Union[int, t.Literal["append"], None] # noqa: UP007 (Python 3.8/3.9 compat)
if t.TYPE_CHECKING:
# Type alias for array-of-tables index (int for position, "append" for new entry, None for default)
IndexType = t.Union[int, t.Literal["append"], None] # noqa: UP007
@dataclass