2.3 KiB
M12-02G Status
status: done task: reclaim preview payload only after the final project-scoped reference is removed updated: 2026-08-17 America/New_York enablingTask: true parityStateChange: false
Scope
Preview reference removal is a guarded catalog mutation: it validates the v2 row, checks the exact base revision, clears only the target asset's preview, advances revision, and commits a manifest hash receipt. Payload reclamation happens only after that reference transaction has completed and only when the committed manifest has zero remaining references to the content hash.
OPFS payload ownership remains project-scoped (projects/<projectId>/assets/sha256/...). Therefore
collection can target only the requested project's file and cannot delete an equal-hash payload
owned and referenced by another project. Non-preview asset metadata is preserved.
Evidence
WEB_TEST_PORT=5599 npm --prefix web run test:asset-preview-reference-gcpassed the artifact unit test 1/1 and real Chromium OPFS/IndexedDB test 1/1.- Project A began with two references to one deduplicated payload. Removing the first at revision
9->10 returned
RETAINED, one remaining reference, and kept the file. - Removing the final reference at revision 10->11 returned
COLLECTEDand removed project A's payload. Project B's equal-hash payload remained present and its preview returned READY/513 bytes. - Reopening project A reproduced revision 11, two null preview references, and unchanged metadata.
Artifact Hashes
- reference GC:
76b9d8ccd3e7992356f33adc694001f9b0ff364788234389eacdb09198d1415e - Chromium suite:
2e9e9b47883997092c5afb0fb7859a484754764de19006e24a8ff2bdeb24f35a - unit suite:
c5de3122b5d8aab17daf0179cb4f5bb0b5d299408818849cbe7b18e40a47706e - manifest:
3449f2ea9488f66ea5e3f5f2423413e8e290d8ffed3b3d941bdeee3f76addd0a - package commands:
7d1db0932fbe7405ffdbd44b770ce7bf9815b9dfb829c1906a06bfff635ae702
Next Task
M12-02H: compare desktop/browser preview pixels with explicit metrics and pass both main-thread
and Offscreen display paths.
Rollback
Remove the reference-GC protocol, Chromium/unit suites, M12-02G manifest, package command, and this
status entry. Restore M12-02G to pending and nextTask to M12-02G. Catalog and parity ledger data
do not require rollback.