mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-02 17:25:22 +03:00
Get size of file from cache
This commit is contained in:
parent
132274579c
commit
1dbe02cbd0
@ -285,10 +285,12 @@ class RecordingMaintainer(threading.Thread):
|
||||
)
|
||||
|
||||
try:
|
||||
segment_size = round(float(os.path.getsize(file_path)) / 1000000, 1)
|
||||
segment_size = round(float(os.path.getsize(cache_path)) / 1000000, 1)
|
||||
except OSError:
|
||||
segment_size = 0
|
||||
|
||||
os.remove(cache_path)
|
||||
|
||||
rand_id = "".join(
|
||||
random.choices(string.ascii_lowercase + string.digits, k=6)
|
||||
)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user