Skip to content

Commit 9466e48

Browse files
committed
Fix mypy
1 parent d4729ba commit 9466e48

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/ansible_creator/resources/collection_project/plugins/action/sample_action.py.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ from __future__ import absolute_import, annotations, division, print_function
1212

1313
__metaclass__ = type # pylint: disable=C0103
1414

15-
from typing import TYPE_CHECKING
15+
from typing import TYPE_CHECKING, cast
1616
from ansible_collections.ansible.utils.plugins.module_utils.common.argspec_validate import ( # type: ignore
1717
AnsibleArgSpecValidator,
1818
)
@@ -60,7 +60,7 @@ class ActionModule(ActionBase): # type: ignore[misc]
6060
# Get the task arguments
6161
if task_vars is None:
6262
task_vars = {}
63-
result = {}
63+
result: Dict[str, Any] = {}
6464
warnings: list[str] = []
6565

6666
# Example processing logic - Replace this with actual action code

tests/fixtures/collection/testorg/testcol/plugins/action/sample_action.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
__metaclass__ = type # pylint: disable=C0103
99

10-
from typing import TYPE_CHECKING
10+
from typing import TYPE_CHECKING, cast
1111
from ansible_collections.ansible.utils.plugins.module_utils.common.argspec_validate import ( # type: ignore
1212
AnsibleArgSpecValidator,
1313
)
@@ -55,7 +55,7 @@ def run(
5555
# Get the task arguments
5656
if task_vars is None:
5757
task_vars = {}
58-
result = {}
58+
result: Dict[str, Any] = {}
5959
warnings: list[str] = []
6060

6161
# Example processing logic - Replace this with actual action code

0 commit comments

Comments
 (0)