Describe the bug
I am seeing if you start an upload transfer while offline, then you force quit the app and reopen it, the task's completion block is called with a nil error and the task's status is 3 (AWSS3TransferUtilityTransferStatusCompleted). This occurs because in didFinishLaunchingWithOptions I register the AWSS3TransferUtility and in that completion block I reassign the progress and completion blocks for the upload tasks.
To Reproduce
Steps to reproduce the behavior:
Which AWS service(s) are affected?
AWSS3TransferUtility
Expected behavior
I expected the transfer tasks to have a status of unknown, so the completion block wouldn't be called, and I would have to retry uploading them as new upload tasks, which is the behavior I see when starting the upload while online.
Environment:
Device Information:
@hipwelljo
I will take a look at this and post an update with my findings. One question I have is - can you check on the server side if the file got uploaded successfully?
Thanks @cbommas! No, it would not be possible to have been uploaded successfully since the device was offline the entire time.
@cbommas Have you been able to take a look at this issue?
@hipwelljo
I was able to reproduce this issue. l will have an update for you in the next few days
@hipwelljo
Just a quick update - I have a fix for this that I am currently testing. Will post back after I finish my testing and get the fix into the release pipeline.
@hipwelljo
The latest rev of the SDK 2.6.34 contains the fix for this issue. With this fix, when the app is force closed, the NSURLSession task associated with the transfer is canceled by the OS and the TransferUtility Task will move to an Error status.
Please give this a try and let me know how it goes.
Confirmed this is working, thanks!