diff --git a/frigate/record.py b/frigate/record.py index 18dedbbaa..23eb77ca6 100644 --- a/frigate/record.py +++ b/frigate/record.py @@ -283,13 +283,9 @@ class RecordingMaintainer(threading.Thread): logger.debug( f"Copied {file_path} in {datetime.datetime.now().timestamp()-start_frame} seconds." ) - try: - segment_size = float(os.stat(file_path)) / 1000 - except OSError: - segment_size = -1 try: - segment_size = float(os.path.getsize(file_path)) / 1000 + segment_size = float(os.path.getsize(file_path)) / 1000000 except OSError: segment_size = -1 diff --git a/frigate/storage.py b/frigate/storage.py index e69de29bb..0a2d96aca 100644 --- a/frigate/storage.py +++ b/frigate/storage.py @@ -0,0 +1,6 @@ +"""Handle storage retention and usage.""" + +import threading + +class StorageMaintainer(threading.Thread): + """Maintain frigates recording storage.""" \ No newline at end of file