tape drive command logging
Continuous Integration / frontend-check (push) Successful in 9m49s
Continuous Integration / backend-tests (push) Successful in 10m11s

This commit is contained in:
2026-04-27 20:35:40 -04:00
parent 57309f8bb7
commit 688206b12d
5 changed files with 185 additions and 111 deletions
+6 -2
View File
@@ -134,12 +134,16 @@ class ScannerService:
try:
if level == "background":
os.nice(19)
if hasattr(psutil.Process(), "ionice"):
if hasattr(psutil.Process(), "ionice") and hasattr(
psutil, "IOPRIO_CLASS_IDLE"
):
process_handle = psutil.Process()
process_handle.ionice(psutil.IOPRIO_CLASS_IDLE)
else:
os.nice(0)
if hasattr(psutil.Process(), "ionice"):
if hasattr(psutil.Process(), "ionice") and hasattr(
psutil, "IOPRIO_CLASS_BE"
):
process_handle = psutil.Process()
process_handle.ionice(psutil.IOPRIO_CLASS_BE, value=4)
except Exception as priority_error: