This commit is contained in:
Ludwig Lehnert
2026-10-03 13:58:22 +00:00
parent 3075d951ba
commit 98b08f6e57
431 changed files with 210848 additions and 60 deletions
+5
View File
@@ -959,7 +959,12 @@ def prepare_state_snapshot(
temporary_root = tempfile.mkdtemp(prefix="backup-state-")
staged_state = os.path.join(temporary_root, "state")
# The document index and previews are derived from backed-up originals.
# Rebuild them on restore rather than copy a live second WAL database.
document_cache = os.path.abspath(os.getenv("DOCUMENT_STATE_ROOT", os.path.join(state_root, "documents")))
document_relative = os.path.relpath(document_cache, state_root)
excluded = {
document_relative,
database_relative,
f"{database_relative}-wal",
f"{database_relative}-shm",