Improved upload chunk integrity - #10377
Merged
Merged
Conversation
Collaborator
Author
|
/backport to stable-34.0 |
Collaborator
Author
|
This depends on #10369 because it also fixes tests which are flaky |
|
i2h3
force-pushed
the
i2h3/upload-chunk-integrity
branch
from
July 16, 2026 07:46
0fb3773 to
19b4bc3
Compare
Signed-off-by: Iva Horn <iva.horn@nextcloud.com>
i2h3
force-pushed
the
i2h3/upload-chunk-integrity
branch
from
July 16, 2026 07:46
19b4bc3 to
9e91734
Compare
Contributor
|
Artifact containing the AppImage: nextcloud-appimage-pr-10377.zip Digest: To test this change/fix you can download the above artifact file, unzip it, and run it. Please make sure to quit your existing Nextcloud app and backup your data. |
claucambra
approved these changes
Jul 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Fixes a chunked-upload integrity bug in the macOS File Provider extension that affects large files (>100 MiB, e.g. Adobe InDesign/Illustrator documents). Previously the chunk-upload identifier diverged across a file's lifecycle —
setStatusForItemMetadataminted a fresh UUID on every.uploadingtransition whilemodifyContentspassed a stale, pre-transition value to the uploader — so an interrupted transfer never actually resumed (it re-uploaded from scratch and leaked both local chunk records and the server-side upload folder), and because chunks carried no binding to the content they came from, a resumed upload whose source had since changed could splice stale server-side chunks into the new version and silently produce a corrupted file. The chunk identifier is now derived deterministically from(itemIdentifier, fileSize, modificationDate): identical content re-uploads under the same id so an interrupted transfer correctly resumes and reuses the chunks already stored, while any content change yields a new id (and a fresh server folder), guaranteeing old chunks can never be mixed into a different version; the item's stale chunk bookkeeping is swept before each upload. The now-redundantchunkUploadIdchurn was removed fromsetStatusForItemMetadata(the Realm field is left in place, so there is no schema migration). This is covered by the resume tests for the create and modify paths (rewritten for the derived id) plus a new test asserting that a content change discards the prior chunks and starts fresh; the full test suite (315 tests) passes.Checklist
AI (if applicable)