سامانه صدور فاکتور و حسابداری

docs: record corrected offline backup tested SHA and I/O safety

davoodmehraban89 committed Oct 14, 2026 at 22:33 UTC 2138dd89a63a25763d1152800107834572b186d4
1 file changed +3 -1
PROJECT_STATE.md
+3 -1
@@ -683,6 +683,8 @@ Owner reports login blocked with generic 'check internet/VPN' network error on l
683 - **Acceptance remains open:** synthetic tests and code review are not a live production backup. Production operation must be run with securely entered database credentials and supported PostgreSQL client on an authorized machine, an off-device second copy must be verified, and an isolated restore test must pass before backup is declared operational.
684
685 - **Implemented scoped deliverables on branch `feat/finora-offline-encrypted-backup-20261014`:** `scripts/finora_local_backup.py` (backup, verify, localhost-only restore-test), `scripts/finora_local_backup_test.py`, `docs/FINORA_OFFLINE_BACKUP_FA.md`, README navigation, Git ignore guards and Quality workflow Python contract step. No R2 subscription, bucket, paid account, GitHub Secrets, Supabase production queries, or backup schedule was created.
686 -- **Independent local verification:** Python 3.13.5 offline unittest **7/7 PASS**, including encrypted-stream contract (with a deliberately fake age executable; real cryptography **not** verified), manifest/hash checks, dump/encryption failure cleanup, blocked remote/ordinary restore targets, local disposable restore process contract and out-of-repository output path. Repeated twice. Exact GitHub blob IDs match locally tested byte content: `scripts/finora_local_backup.py` `b56e22d6d292570eee03bbccfa69ed7f123a09dd` and `scripts/finora_local_backup_test.py` `edd94ec3fea2678127e9ebba0fbc1e5661cb89ee`.
686 +- **Independent local verification:** Python 3.13.5 offline unittest **7/7 PASS**, including encrypted-stream contract (with a deliberately fake age executable; real cryptography **not** verified), manifest/hash checks, dump/encryption failure cleanup, blocked remote/ordinary restore targets, local disposable restore process contract and out-of-repository output path. Repeated twice. Exact GitHub blob IDs match locally tested byte content: `scripts/finora_local_backup.py` `f38d6778d355818588e3b59113781bce2d4e6b8e` and `scripts/finora_local_backup_test.py` `edd94ec3fea2678127e9ebba0fbc1e5661cb89ee`.
687 - **Explicit remaining acceptance:** live Production pg_dump, real age encryption/decryption, verified offline second copy, actual isolated PostgreSQL restore, Supabase Storage and external configuration backup all **NOT TESTED**. Windows owner device `DESKTOP-71SJ63M` was offline (47 hours since last seen); this assistant's connected Supabase projects are not the production project. Need owner to install client tools, locally generate and safeguard age key, obtain production database connection details (do not share password here), run commands on authorized connected host and provide non-sensitive success/failure evidence. Automatic scheduling is NOT configured.
688 - **Rollback:** revert scoped PR, remove optional Python CLI/tests/docs; since no production DB writes or new subscriptions occurred, no DB rollback is needed. Quality/Security CI and merge **PENDING**.
689 +
690 +- **Safety correction before final CI:** backup process now catches interruption for ciphertext/manifest cleanup and consumes `pg_restore` stderr asynchronously to avoid pipe deadlock during failures. Reverified **7/7 local synthetic tests PASS** on exact new script blob `f38d6778d355818588e3b59113781bce2d4e6b8e`; GitHub quality/security remain PENDING. No real backup or recovery claim.