mirror of
https://codeberg.org/privacy1st/de-p1st-monitor
synced 2024-11-21 19:33:18 +01:00
v0.10.3
This commit is contained in:
parent
b5416a98ba
commit
a53639408e
@ -3,7 +3,7 @@
|
||||
|
||||
[metadata]
|
||||
name = de.p1st.monitor
|
||||
version = 0.10.2
|
||||
version = 0.10.3
|
||||
author = Daniel Langbein
|
||||
author_email = daniel@systemli.org
|
||||
description = periodically monitor and warn
|
||||
|
@ -96,11 +96,14 @@ class DriveLogger(Logger):
|
||||
:raise BlkidException: If UUID could not be determined.
|
||||
"""
|
||||
returncode, stdout, stderr = execute_capture(['blkid', '-s', 'UUID', '-o', 'value', f'{device}'])
|
||||
|
||||
if returncode != 0:
|
||||
raise BlkidException(f'blkid failed with returncode {returncode}\nstdout: {stdout}\nstderr: {stderr}')
|
||||
|
||||
return stdout.strip()
|
||||
uuid = stdout.strip()
|
||||
if len(uuid) == 0:
|
||||
raise BlkidException('blkid had exit code zero, but the UUID is empty')
|
||||
|
||||
return uuid
|
||||
|
||||
@classmethod
|
||||
def get_temp_from_device(cls, device: Path) -> int:
|
||||
|
Loading…
Reference in New Issue
Block a user