Keeping a capture: a full storage quota makes Keep do nothing, with no message #16
Labels
No labels
bug
documentation
enhancement
performance
security
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Postulo/postulo-chromium#16
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found on 2026-09-29 in a read-only review of postulo-chromium at
7998de372, following every storage write from a button.Related to postulo/postulo-firefox#1.
Captures and their slimmed pages live in
storage.local, which Chromium caps at 10 MB withoutunlimitedStorage(the manifest no longer asks for it). A kept page stays until it is sent, and nothing sends a kept capture by itself. Once the quota is reached,storage.local.setrejects. The handlers that add a capture have notry, so the rejection is unhandled and the click does nothing visible; Send shows the browser's raw, untranslated quota message.src/popup.js:133-141, the Keep in this browser handler:const record = await save("kept");outside anytry.src/popup.js:310-318, Keep for the ticked postings of a results page, throughsavePickedandstore.addMany.src/captures.js:145-161, Save in the list's editor, when the corrected fields are longer than before.src/lib/store.js:59-68(add) and:76-101(addMany), oneset()of record, page and index that fails as a whole.src/popup.js:143-180, Send:save("waiting")is inside thetry, andexplain()(src/lib/i18n.js:55-63) falls back toerror.message, the browser's English text.PRIVACY.md:25-27: "at most 512 KB", whileMAX_PAGE(src/lib/parse.js:841) is 512 × 1024 UTF-16 characters and the quota counts bytes of the JSON-serialised value, so a page in a non-Latin script, or one heavy with quoted attributes, takes more.try/catchand report a translated sentence throughsay(), for example "This browser's storage for Postulo is full: send or delete some captures." (a new key in all 40 catalogues); recognise the quota error inexplain()rather than showing its text. Optionally show the space used (storage.local.getBytesInUse) on Captures in this browser. Say "characters" inPRIVACY.md, or measure the page in bytes.Delete, Clear the ones sent and Hold back only shrink what is stored, so the quota does not refuse them.
Done when
test/outbox.test.mjs(or a newtest/store.test.mjs) givesmakeStorean area whosesetrejects with a quota error and asserts that the error reaching the caller carries a translatable key; the Keep, Keep-ticked and editor Save handlers each catch it and callsay(..., true).