forked from Github/frigate
Round the timestamp value read from .vacuum file to prevent potential errors caused by float values (#6800)
This commit is contained in:
committed by
GitHub
parent
ff1b5c87aa
commit
3efa77f302
@@ -196,7 +196,7 @@ class FrigateApp:
|
|||||||
if os.path.exists(f"{CONFIG_DIR}/.vacuum"):
|
if os.path.exists(f"{CONFIG_DIR}/.vacuum"):
|
||||||
with open(f"{CONFIG_DIR}/.vacuum") as f:
|
with open(f"{CONFIG_DIR}/.vacuum") as f:
|
||||||
try:
|
try:
|
||||||
timestamp = int(f.readline())
|
timestamp = round(float(f.readline()))
|
||||||
except Exception:
|
except Exception:
|
||||||
timestamp = 0
|
timestamp = 0
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user