Page MenuHomePhabricator

Allow continuing the partially-complete upload in stashed mode after warning
Open, LowPublic

Description

If warnings occur and aren't ignored during the upload of a chunk, the chunk is stashed as a separate "file" rather than being a part of a chunked upload session.

It would be helpful if this separately-stashed chunk could be used as input to the chunked-uploading process so it wouldn't have to be re-uploaded if the warning is to be ignored.

Event Timeline

XZise raised the priority of this task from to Needs Triage.
XZise updated the task description. (Show Details)
XZise added a subscriber: XZise.
Restricted Application added subscribers: Steinsplitter, Aklapper. · View Herald Transcript
Anomie set Security to None.

I rewrote the description since it seemed to be describing the opposite of reality, possibly due to terminology confusion between the stash and the way chunked uploads work.

As for the request itself, something like this seems like it might work:

  • Add a stashedchunk or chunkfromstash (or whatever color the bikeshed should be) parameter that works just like chunk but the value is a filekey.
  • When that parameter is used, load up the filekey from stash to populate $chunkPath and $chunkSize in ApiUpload::getChunkResult().
  • Then at the if ( $this->mParams['offset'] == 0 ) { bit, just reuse the passed-in filekey if it's the first chunk or delete the passed-in filekey after the ->addChunk() call succeeds if it's not the first chunk.

No. That's about looking in the stash for UI purposes, while this is about looking in the stash for new backend functionality.

Jdforrester-WMF renamed this task from Allow continuing the upload in stashed mode after warning to Allow continuing the partially-complete upload in stashed mode after warning.Sep 14 2015, 11:49 PM
Jdforrester-WMF triaged this task as Low priority.
Jdforrester-WMF moved this task from Untriaged to Backlog on the Multimedia board.