mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Merge branch 'bugfix/disk-data' into tweak/dashboard-storage
This commit is contained in:
commit
709539417f
@ -191,6 +191,7 @@ class Stats:
|
||||
# ENOENT, pop-up a Windows GUI error for a non-ready
|
||||
# partition or just hang.
|
||||
continue
|
||||
try:
|
||||
usage = psutil.disk_usage(part.mountpoint)
|
||||
disk_data.append(
|
||||
{
|
||||
@ -206,6 +207,9 @@ class Stats:
|
||||
"mount": part.mountpoint,
|
||||
}
|
||||
)
|
||||
except PermissionError:
|
||||
logger.debug(f"Permission error accessing {part.mountpoint}")
|
||||
continue
|
||||
|
||||
return disk_data
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user