NVR with realtime local object detection for IP cameras
TypeScript aicameragoogle-coralhome-assistanthome-automationhomeautomationmqttnvrobject-detectionrealtimertsptensorflow
Migrate export filenames (#11005)
Nicolas Mowen8230813b795c
diff --git a/frigate/util/builtin.py b/frigate/util/builtin.pyindex be91421f94..1536d9799a 100644--- a/frigate/util/builtin.py+++ b/frigate/util/builtin.py@@ -223,8 +223,6 @@ def update_yaml_file(file_path, key_path, new_value):data = yaml.load(f)data = update_yaml(data, key_path, new_value)- with open("/config/test.yaml", "w") as f:- yaml.dump(data, f)with open(file_path, "w") as f:yaml.dump(data, f)diff --git a/frigate/util/config.py b/frigate/util/config.pyindex fb7aa3ef5d..1192ac9de7 100644--- a/frigate/util/config.py+++ b/frigate/util/config.py@@ -6,7 +6,7 @@ import shutilfrom ruamel.yaml import YAML-from frigate.const import CONFIG_DIR+from frigate.const import CONFIG_DIR, EXPORT_DIRlogger = logging.getLogger(__name__)@@ -46,6 +46,16 @@ def migrate_frigate_config(config_file: str):yaml.dump(new_config, f)previous_version = 0.14+ logger.info("Migrating export file names...")+ for file in os.listdir(EXPORT_DIR):+ if "@" not in file:+ continue++ new_name = file.replace("@", "_")+ os.rename(+ os.path.join(EXPORT_DIR, file), os.path.join(EXPORT_DIR, new_name)+ )+with open(version_file, "w") as f:f.write(str(CURRENT_CONFIG_VERSION))