Add more type hints.

This commit is contained in:
Felix Fontein
2025-11-30 12:00:56 +01:00
parent fe478bd1bb
commit 93cd3755a0
30 changed files with 354 additions and 298 deletions

View File

@@ -52,7 +52,7 @@ def snap_runner(module: AnsibleModule, **kwargs) -> CmdRunner:
return runner
def get_version(runner: CmdRunner):
def get_version(runner: CmdRunner) -> dict[str, list[str]]:
with runner("version") as ctx:
rc, out, err = ctx.run()
return dict(x.split() for x in out.splitlines() if len(x.split()) == 2)