fix(propagateupload): ensure file size stays the same for new uploads - #9823
Conversation
|
/backport to stable-33.0 please |
|
/backport to stable-4.0 |
|
|
The issue has been open and plagueing users for several months now. But it seems almost fixed? |
Signed-off-by: Jyrki Gadinger <[email protected]>
It is possible that the sync engine discovers a file with a small enough file size to use the old V1 upload propagator. This is fine unless the file size is still growing between discovery and propagation; should the file grow large enough before propagation starts the propagator job may attempts to upload the file in chunks using the old (removed with Nextcloud 30) chunking mechanism. Since Nextcloud 30 this no longer works as it only has support for V2 upload chunking (PropagateUploadFileNG), resulting in broken partial uploads while the client believes everything got uploaded. The PropagateUploadFileCommon job already checks whether the file is different, however relying on just the mtime is not enough for new files. Signed-off-by: Jyrki Gadinger <[email protected]>
987dbfe to
8ba9a83
Compare
|
/backport to stable-34.0 please |
|
Artifact containing the AppImage: nextcloud-appimage-pr-9823.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. |
|
|
Thanks, finally! |
|
ty for fixing and merging into the master branch. I was so happy to finally be settled at my last location to work on foss and being more helpful than life happened once again and I'm now starting over in a much better area. Look before you leap or otherwise you pay twice. |
Changes:
[sonarcloud.yml (line 4)]
Runs after pushes to master, keeping the comparison baseline current.
Handles draft-PR checks safely for both push and PR events.
Cancels superseded Sonar runs for the same PR/branch.
Removed the obsolete filesystem cache step.
[sonar-project.properties (line 1)]
Removed deprecated sonar.language.
Removed duplicate and malformed cache settings.
Removed sonar.cfamily.threads=2, allowing Sonar to use all detected logical CPUs.
Preserved the correct coverage-report path.
[propagateupload.cpp (line 444)]
Fixed the one Sonar finding actually introduced by PR nextcloud#9823 by making the variable const.
Assisted-by: Codex:GPT-5
Signed-off-by: Rello <[email protected]>




It is possible that the sync engine discovers a new file with a small enough file size to use the old V1 upload propagator. This is fine unless the file is still being written to between discovery and propagation (this could happen when copying large files); should the file grow large enough before propagation starts the propagator job may attempts to upload the file in chunks using the old (removed with Nextcloud 30) chunking mechanism. Since Nextcloud 30 this no longer works as it only has support for V2 upload chunking (PropagateUploadFileNG), resulting in broken partial uploads while the client believes everything got uploaded.
The PropagateUploadFileCommon job already checks whether the file is different, however relying on just the mtime is not enough for newly discovered files.
Resolves #9271