Skip to content
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

Cancel Without Resume Data When Possible #3538

Merged
merged 1 commit into from
Jan 30, 2022

Conversation

jshier
Copy link
Contributor

@jshier jshier commented Jan 8, 2022

Issue Link πŸ”—

#3536

Goals ⚽

This PR reverts the fix from #3102 as the underlying bug doesn't seem to actually affect Alamofire, perhaps due to our use of locking around cancellation.

Implementation Details 🚧

Just call cancel() rather than cancel(producingResumeData:) with an empty closure, as doing so produced resume data unconditionally and won't be cleaned up until temp storage is purged.

Testing Details πŸ”

Original tests intact, nothing new. Should continue passing on all OSes. Added older OS coverage in another PR to ensure that DownloadRequest's tests continue to pass.

@jshier jshier force-pushed the bug/unnecessary-download-data branch from 4c5a292 to 6f9d274 Compare January 30, 2022 03:31
@jshier jshier merged commit c05c2b5 into master Jan 30, 2022
@jshier jshier deleted the bug/unnecessary-download-data branch January 30, 2022 03:57
@jshier jshier added this to the 5.6.0 milestone Apr 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant