mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Add basic typing for module_utils.
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
|
||||
from ansible_collections.community.general.plugins.module_utils import deps
|
||||
|
||||
|
||||
@@ -13,7 +15,7 @@ with deps.declare("packaging"):
|
||||
|
||||
|
||||
class PackageRequirement:
|
||||
def __init__(self, module, name):
|
||||
def __init__(self, module: AnsibleModule, name) -> None:
|
||||
self.module = module
|
||||
self.parsed_name, self.requirement = self._parse_spec(name)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user