Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Hvornum <anton.feeds@gmail.com>2021-03-09 11:56:33 +0100
committerAnton Hvornum <anton.feeds@gmail.com>2021-03-09 11:56:33 +0100
commitf045462c9a105b6272db4c61e8b29fc1ae059c8a (patch)
treed970fa4198ab9744b5fc98635680f931009d2b19
parent4e8084bddb989646bf74b6c8883fc66622441221 (diff)
Fixed a issue with blkid where it would raise an exception when there was not filesystem on the partition.
-rw-r--r--archinstall/lib/disk.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/archinstall/lib/disk.py b/archinstall/lib/disk.py
index db58f3ce..3f51733a 100644
--- a/archinstall/lib/disk.py
+++ b/archinstall/lib/disk.py
@@ -487,6 +487,8 @@ def get_mount_info(path):
return output['filesystems'][0]
def get_filesystem_type(path):
- if (handle := sys_command(f"blkid -o value -s TYPE {path}")).exit_code != 0:
- return None
- return b''.join(handle).strip().decode('UTF-8') \ No newline at end of file
+ try:
+ handle = sys_command(f"blkid -o value -s TYPE {path}")
+ return b''.join(handle).strip().decode('UTF-8')
+ except SysCallError:
+ return None \ No newline at end of file