Skip to content

Commit 3712afd

Browse files
committed
Define AnsibleUnicodeItems alias if type checking
I did this as the type alias only exists if TypeAlias is imported, which happens only if the code is being type-checked.
1 parent 66c6155 commit 3712afd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

rules/task_values.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@
3131
from ansiblelint.utils import Task
3232
from jinja2.nodes import Node
3333

34-
AnsibleUnicodeItems: TypeAlias = dict[int, AnsibleUnicode]
34+
AnsibleUnicodeItems: TypeAlias = dict[int, AnsibleUnicode]
35+
3536
spell_checker = SpellChecker()
3637
init_plugin_loader() # required before using loaders
3738
spell_checker.word_frequency.load_text_file(Path("./docs/dictionary.txt"))

0 commit comments

Comments
 (0)