-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix possible double writing of the uploaded client files in Upload-Multiple requests #6952
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #6952 +/- ##
===========================================
- Coverage 82.59% 82.34% -0.26%
===========================================
Files 360 361 +1
Lines 38926 39169 +243
Branches 3570 3586 +16
===========================================
+ Hits 32150 32252 +102
- Misses 6776 6917 +141
|
Would it be possible to have this fix in the next release? Thank you very much! |
task_id, _ = create_task(self._USERNAME, task_spec, task_data) | ||
|
||
# check that the original chunk image have the original size | ||
# this is less accurate than checking the uploaded file directly, but faster |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you clarify why this is less accurate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because we're not checking the original problem exactly, as it was with raw uploaded files. The chunks may get processed data, which can be correct for some foreign reasons, which can shadow the initial problem.
Co-authored-by: Roman Donchenko <roman@cvat.ai>
…ltiple requests (cvat-ai#6952) Fixes cvat-ai#6878 In the case of big files (>2.5 MB by default), the uploaded files could be write-appended twice, leading to bigger raw file sizes than expected. This PR fixes the behavior by excluding repetitive writes where it was not supposed. - Fixed double append-writing of the uploaded files when Upload-Multiple requests are used - Fixed potential DB - disk inconsistencies in the case of upload errors - Added tests
Fixes #6878
In the case of big files (>2.5 MB by default), the uploaded files could be write-appended twice,
leading to bigger raw file sizes than expected. This PR fixes the behavior by excluding repetitive
writes where it was not supposed.
Motivation and context
How has this been tested?
Checklist
develop
branch(cvat-canvas,
cvat-core,
cvat-data and
cvat-ui)
License
Feel free to contact the maintainers if that's a concern.