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.

XZise created this task.Sep 14 2015, 4:07 PM
XZise updated the task description. (Show Details)
XZise raised the priority of this task from to Needs Triage.
XZise added a subscriber: XZise.
Restricted Application added a project: Multimedia. · View Herald TranscriptSep 14 2015, 4:07 PM
Restricted Application added subscribers: Steinsplitter, Aklapper. · View Herald Transcript
Anomie updated the task description. (Show Details)Sep 14 2015, 4:12 PM
Anomie set Security to None.
Restricted Application added a subscriber: Matanya. · View Herald TranscriptSep 14 2015, 4:12 PM
Anomie added a subscriber: Anomie.Sep 14 2015, 4:22 PM

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.
Anomie moved this task from Unsorted to Needs Code on the MediaWiki-API board.Sep 14 2015, 4:23 PM

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.