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

Handle connection being closed unexpectedly mid download #96

Closed
hickford opened this issue Oct 8, 2012 · 2 comments
Closed

Handle connection being closed unexpectedly mid download #96

hickford opened this issue Oct 8, 2012 · 2 comments
Labels
enhancement New feature or enhancement

Comments

@hickford
Copy link
Contributor

hickford commented Oct 8, 2012

If the HTTP connection is closed part way through the response, wget will bork

$ wget http://download.sysinternals.com/files/SysinternalsSuite.zip
Length: 13080395 (12M) [application/x-zip-compressed]
Saving to: `SysinternalsSuite.zip.1'

99% [=====================================> ] 13,066,240  4.90K/s   in 37s

2012-10-08 11:31:28 (345 KB/s) - Connection closed at byte 13066240. Retrying.

Wget will retry the download. My browsers silently accept the truncated download. Httpie too silently accepts the truncated download. I don't know whether httpie should retry, but I think httpie should at least warn that the response is incomplete.

NB. The truncation of that particular request only happens in my dodgy network so you will need your own example to test this behaviour.

@hickford
Copy link
Contributor Author

@jkbrzt
Copy link
Member

jkbrzt commented Nov 10, 2012

I'm considering adding a --download mode which would make HTTPie behave similarly to wget (progress bar, resume, etc).

Related: #97

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or enhancement
Projects
None yet
Development

No branches or pull requests

2 participants