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

Allowed partial response on timeout if fail on dataloss is set to false #3492

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Allowed partial response on timeout if fail on dataloss is set to false #3492

wants to merge 3 commits into from

Conversation

nasirhjafri
Copy link

@nasirhjafri nasirhjafri commented Nov 15, 2018

If DOWNLOAD_FAIL_ON_DATALOSS is set to true in settings ant the request times out we need partial responses, as discussed here #3407

I've added a new callback in the above-mentioned case instead of canceling the Deferred and returned the result instead of raising a TimeoutError.

Resolves #3407

@codecov
Copy link

codecov bot commented Nov 15, 2018

Codecov Report

Merging #3492 into master will increase coverage by 0.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #3492      +/-   ##
==========================================
+ Coverage   84.38%   84.39%   +0.01%     
==========================================
  Files         167      167              
  Lines        9376     9383       +7     
  Branches     1392     1393       +1     
==========================================
+ Hits         7912     7919       +7     
  Misses       1206     1206              
  Partials      258      258
Impacted Files Coverage Δ
scrapy/core/downloader/handlers/http11.py 92.7% <100%> (+0.19%) ⬆️

@nasirhjafri
Copy link
Author

@kmike Can you please review it. Thanks!

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.

Can't get partial response body after timeout
1 participant