Repository navigation
Conversation
The browser writes one TAR member per selected file. Count these entries so that implicit folders do not reject imports at the limit.
Quality report
Gate: passedNothing found by knip. Proof weightProduct +735 lines against proof +1037 lines (tests, specs). Measures on added lines
New duplicate code, exact token clones (jscpd) Test runtimeThis run against the median of the last 5 successful
Every table: this run's summary. |
|
Automated review: APPROVE The correction clears the only blocking finding. Ship the reviewed implementation after the controller and image rollout and the real-volume rehearsal pass. The independent whole-batch review covered admission, ownership, transaction rollback and replay, storage readings, upload receipts, cancellation, and Home states. The correction recheck covered all four changed files. Original finding, now resolved: P2 - False member-limit refusal - cloud-import-browser.ts:106. The forecast counts parent directories that the TAR writer never emits. With max_members=1, one nested file forecasts two members and Home blocks a valid import. Real encryption/decryption confirmed one archive entry. Count the entries actually written and correct the Home test that expects this refusal. The writer now reports only the file entries it emits. The revised Home case admits a nested file at the published member limit. Independent real encryption and decryption measured one forecast member and one archive member, with no refusal. The ciphertext forecast and actual size both remained 2,248 bytes. Independent validation at this head: 19 tests passed using node --import tsx --experimental-test-module-mocks --test --test-concurrency=1 on src/app/exomem/home/tests/home-import.test.tsx and src/lib/exomem-hosted/tests/cloud-import-browser.test.ts. The initial review also ran 43 scoped checks successfully. git diff --check passed. C4: absent. C6: the added schemas, units and stop codes implement the closed import protocol; the SHA expression checks format. Their reasons are present. No unresolved unsound mechanism was found. Weight against the PR base, from git diff --numstat: 28 files.
Proof outweighs product because it covers PostgreSQL growth, rollback and replay, browser reload receipts, and rendered workflow states. I did not independently rerun PostgreSQL or live Chrome; I inspected the supplied integration and DevTools evidence. Current-head CI and the controller/image rollout and real-volume rehearsal remain delivery dependencies. Local publication and growth remain deferred under the separate capacity-accounting gate. Blocking: 0 |
|
Automated review: APPROVE Current call: ship the combined admission, resumable-upload and filing-count implementation after the existing rollout dependencies pass. No blocking findings remain. This record extends the prior P4/P5 review to all 11 files in the P7 delta and their combined contracts. The server reads the owned import before requesting its scoped filing count. The path comes from the stored import ID. The existing Home channel retains the session's reviewer credential and tenant binding. Bearer status does not acquire a Home principal. Only a complete reply with a nonnegative safe integer becomes a Filed count. Unavailable, older, incomplete, malformed or refused replies leave the count unknown. Home keeps Filed distinct from staged and selected totals. The supplied real MCP-to-Home proof checks distinct original paths across overlapping runs, and DevTools evidence covers complete and unknown states at desktop and phone widths in both themes. Original finding, now resolved: P2 - False member-limit refusal - cloud-import-browser.ts:106. The forecast counts parent directories that the TAR writer never emits. With max_members=1, one nested file forecasts two members and Home blocks a valid import. Real encryption/decryption confirmed one archive entry. Count the entries actually written and correct the Home test that expects this refusal. The prior correction removed the implicit parent count. Independent encryption and decryption then measured one forecast member and one archive member, with no refusal. The ciphertext forecast and actual size both remained 2,248 bytes. The revised Home test admits that nested file at the published member limit. Earlier independent runtime checks passed 43 scoped tests and 19 correction checks. The P7 review reused the supplied isolated PostgreSQL, real MCP-to-Home and DevTools evidence; it did not repeat those runtime checks. The current combined diff passes git diff --check. CI on this exact head remains a delivery dependency. C4: absent. C6: added schemas, units and stop codes implement the closed import protocol; SHA expressions check format. P7 uses structured output validation and the existing server-selected staging path. No unresolved unsound mechanism was found. Weight against the PR base, from git diff --numstat: 32 files.
Proof outweighs product because it covers transactional growth, replay and rollback, durable reload receipts, owner isolation, reviewer credential lineage and truthful count states. The controller and image rollout and the real-volume rehearsal remain explicitly open deployment dependencies. This review does not authorize rollout. Local publication and growth remain deferred under the separate capacity-accounting gate. Blocking: 0 |
This reverts commit da9916c.
…ission-rebase # Conflicts: # src/app/exomem/home/__tests__/home-import.test.tsx # src/app/exomem/home/home-import-panels.tsx # src/app/exomem/home/home-import.tsx # src/lib/exomem-hosted/__tests__/cloud-import-browser-file.test.ts # src/lib/exomem-hosted/cloud-import-browser-api.ts # src/lib/exomem-hosted/cloud-import-browser-file.ts # src/lib/exomem-hosted/cloud-import-browser.ts # src/lib/exomem-hosted/cloud-import-selection.ts # src/lib/exomem/theme-script.generated.ts
…he Home preflight Use the capacity ratio only when the usage reading is at least as recent as the capacity reading, never below 1, and clamp against the larger of the published cap and the current size. Home warns about free space only when growth cannot cover the need, refuses an encrypted copy above the multipart ceiling, needs the growth deadline only for the wait text, and says when limits could not be read. The staged size modifies the existing staged-originals requirement; hidden items stay out of the selection.
…r the local cutover
…l writes The closed dialog keeps reading an import that waits for growth, a paused or stopped upload outranks the growth wait on the row, and the upload loop reads less often while storage grows. storage_ready holds once observed capacity covers the requirement. Admission writes the cell only for real growth, an owner with no import gets an empty reply instead of 404, the receipt goes before its ciphertext, and stop reasons live in one table. New dialog text is labelled rows and one-line states.
…on one line The preflight shows the selected files against the published maximum less the series file's entry. The growth row keeps a size and its unit together. The change text gives the real reason for skipping no-op growth writes, and the rendered pass ticks task 3.2.
|
Automated review: APPROVE Current call: ship 1e5a122 once the separate risk-lens pass approves. CI on this head passed every job, including the Home end-to-end journey. All four round-1 blocking findings are fixed and checked at this head, and what remains is wording and small refactors. Risk lens: admission writes billed volume growth that cannot be undone, sized from a client-declared byte count. Weight against the PR base: product +716/-94, proof +1007/-92 (tests and e2e +902/-8, OpenSpec +105/-84). Round-1 blocking findings, now resolved:
Also fixed from round 1: no cell write when no growth is needed (cloud-imports.ts:350-355); Non-blocking:
C4: absent. C6: the added schemas, units, stop codes and poll intervals implement the closed import protocol, each with a reason. Scale: the growth wait polls every 15 s, and no N+1 query or unbounded query was added. The open-first status sort is old debt. |
|
Automated review: APPROVE Ship. Admission, growth within the cap, replay before checks, rollback on an open-slot conflict, the typed refusals, the unpublished-limits path, owner scoping and the part-receipt resume are correct. Tests cover them at the PostgreSQL, browser and Home boundaries. Weight: product +716/-94; proof +1007/-92 (tests +902/-8, OpenSpec +105/-84). The change grows storage irreversibly and spends money, which justifies the proof; jscpd flags five duplicated test setup blocks. C4: absent. C6: no unsound mechanism; the digest regex, the new STOPS codes and the C5 key schemas each carry a reason line. Scale: no defect in the change; old debt: the status query sorts every import of the cell by an expression to pick one row. Non-blocking findings:
|
A part receipt the browser cannot write no longer stops the upload. Limit refusals name their next step once, show files against the limit in the same terms as the preflight, and the series entry count lives beside the archive builder. The growth limit is one component that says it counts from the upload's start. The reply passes published limits whole for each reader to check, the growth write returns only the cell columns it reads, and C5 timestamps are measurement times.
|
Automated review: APPROVE Ship. This recheck covers only the follow-up commit against the first round's findings. Findings 1, 2, 3, 4 and 6 are fixed, and the receipt and refusal fixes each have a test that fails if the fix is reverted. Finding 5 is withdrawn: cellctl holds the key until a capacity reading covers the requirement, so the import really does wait. Weight of the follow-up: product +44/-29, proof +32/-2. Status of the earlier findings:
New in this commit, non-blocking: |
…mment on its function
|
Automated review: APPROVE Ship. This recheck covers only 7236b6f..1135681, and the diff is sound. Weight of the follow-up: product +9/-6, proof +1/-1.
Non-blocking: Home's list of codes whose STOPS text already names the next step lives apart from the STOPS table. A flag on each STOPS entry would keep both in one place. |
|
Automated review: APPROVE Current call: ship 1135681 once the separate risk-lens pass approves. Every blocking finding from all four rounds is fixed and was checked at this head, and CI passes every check. Risk lens: admission writes billed volume growth that cannot be undone, sized from a client-declared byte count. Weight against the PR base: product +735/-95, proof +1037/-92 (tests and e2e +932/-8, OpenSpec +105/-84). Blocking findings, all resolved: Round 1 (4):
Round 3 (1):
Round 4 also moved Non-blocking debt: the growth UPDATE's RETURNING list repeats lockCell's column list in cloud-imports.ts. Share one list when either changes. C4: absent. C6: the added schemas, units, stop codes, poll intervals and code branches implement the closed import protocol, each with a reason. Scale: the growth wait polls every 15 s, and no N+1 query or unbounded query was added. The open-first status sort is old debt. |
Cloud import admission and Home now use the import limits that each cell publishes in C5. An import that cannot succeed is refused before the owner encrypts and uploads it, and an import that needs more storage grows the vault within the published cap first.
Why
Without published limits, Home and the import API accept a selection that the cell later refuses, after the owner has spent the time to encrypt and upload it. A vault whose storage is too small has no way to grow for an import without an operator.
What changed
IMPORT_TOO_MANY_FILESorIMPORT_STORAGE_LIMIT, and prepare-upload refuses withIMPORT_PARTS_LIMIT. Each refusal carries a typedlimit.The earlier adopted-count work is removed. Home already reads each import's filing through the cell's public
inspect_memoryimports.status, which reports the filed counts, and a cell refuses the private tool that work used. The OpenSpec change marks its tasks 5.1 and 5.2 as superseded.Proof
Rollout
Merge only after the paired controller change completes its real-volume rehearsal. Then roll out in the order that the OpenSpec change's task 6.2 names. The C5 migration and grants are already on
main.Risk and undo
Growth on demand can raise any vault's storage up to the published cap. To undo, set the cell's
import_limitsto NULL, which returns admission to the earlier behaviour, and roll the deployment back. Grown volumes stay grown.Weight: product +716/-94, proof +1007/-92, across 30 files. The proof includes the OpenSpec change text.