-
Notifications
You must be signed in to change notification settings - Fork 2.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
[stable10] Fix folder upload race condition #29435
Conversation
Codecov Report
@@ Coverage Diff @@
## stable10 #29435 +/- ##
===========================================
Coverage 59.25% 59.25%
Complexity 17766 17766
===========================================
Files 1062 1062
Lines 59513 59513
===========================================
Hits 35264 35264
Misses 24249 24249 Continue to review full report at Codecov.
|
When uploading the same folder twice, sometimes a race condition is triggered where some of the first uploaded items finish faster and trigger the "end of transfer" event even though there are further items to upload. This fix prevents the end of transfer event to clear the list of uploads so it can continue.
89a761f
to
0d0d3d7
Compare
} | ||
var path = OC.joinPaths(basePath, this.getFile().relativePath || '', this.getFile().name); |
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.
I'd rather move the this.getFile().relativePath || ''
up to avoid the operation being evaluated in the function because it isn't common, but taking into account this is the only change I see for a backport, I'm fine to leave this as tech debt.
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.
Thanks. Considering that this isn't happening in a big loop I think this bit is acceptable.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Backport of #29393 to stable10