Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall/lib/disk/fido.py
diff options
context:
space:
mode:
Diffstat (limited to 'archinstall/lib/disk/fido.py')
-rw-r--r--archinstall/lib/disk/fido.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/archinstall/lib/disk/fido.py b/archinstall/lib/disk/fido.py
index 436be4d4..2a53b551 100644
--- a/archinstall/lib/disk/fido.py
+++ b/archinstall/lib/disk/fido.py
@@ -2,7 +2,8 @@ from __future__ import annotations
import getpass
import logging
-from typing import List
+from pathlib import Path
+from typing import List, Optional
from .device_model import PartitionModification, Fido2Device
from ..general import SysCommand, SysCommandWorker, clear_vt100_escape_codes
@@ -36,12 +37,12 @@ class Fido2:
# to prevent continous reloading which will slow
# down moving the cursor in the menu
if not cls._loaded or reload:
- ret = SysCommand(f"systemd-cryptenroll --fido2-device=list").decode('UTF-8')
+ ret: Optional[str] = SysCommand(f"systemd-cryptenroll --fido2-device=list").decode('UTF-8')
if not ret:
log('Unable to retrieve fido2 devices', level=logging.ERROR)
return []
- fido_devices = clear_vt100_escape_codes(ret)
+ fido_devices: str = clear_vt100_escape_codes(ret) # type: ignore
manufacturer_pos = 0
product_pos = 0
@@ -58,7 +59,7 @@ class Fido2:
product = line[product_pos:]
devices.append(
- Fido2Device(path, manufacturer, product)
+ Fido2Device(Path(path), manufacturer, product)
)
cls._loaded = True