summaryrefslogtreecommitdiff
path: root/kvmd/apps/otgconf
diff options
context:
space:
mode:
authorMaxim Devaev <[email protected]>2022-09-04 18:08:40 +0300
committerMaxim Devaev <[email protected]>2022-09-04 18:08:40 +0300
commitee3e224e396494cd0d69bb6167087a071a20349c (patch)
tree5becd28570e58a03c6e1e231d0db24c264a73f88 /kvmd/apps/otgconf
parent4b75221e9470b4a009955d7677f16adf8e23e302 (diff)
new typing style
Diffstat (limited to 'kvmd/apps/otgconf')
-rw-r--r--kvmd/apps/otgconf/__init__.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/kvmd/apps/otgconf/__init__.py b/kvmd/apps/otgconf/__init__.py
index 389e1721..1a1e0f99 100644
--- a/kvmd/apps/otgconf/__init__.py
+++ b/kvmd/apps/otgconf/__init__.py
@@ -26,10 +26,7 @@ import contextlib
import argparse
import time
-from typing import List
-from typing import Dict
from typing import Generator
-from typing import Optional
import yaml
@@ -64,7 +61,7 @@ class _GadgetControl:
with open(udc_path, "w") as udc_file:
udc_file.write(udc)
- def __read_metas(self) -> Generator[Dict, None, None]:
+ def __read_metas(self) -> Generator[dict, None, None]:
for meta_name in sorted(os.listdir(self.__meta_path)):
with open(os.path.join(self.__meta_path, meta_name)) as meta_file:
yield json.loads(meta_file.read())
@@ -111,7 +108,7 @@ class _GadgetControl:
# =====
-def main(argv: Optional[List[str]]=None) -> None:
+def main(argv: (list[str] | None)=None) -> None:
(parent_parser, argv, config) = init(
add_help=False,
cli_logging=True,