Opened at 2010-09-03T16:40:11Z
Last modified at 2010-09-06T06:55:35Z
#1193 new enhancement
adding support for http byte range in http_common.do_http
Reported by: | guyzmo | Owned by: | guyzmo |
---|---|---|---|
Priority: | major | Milestone: | undecided |
Component: | code-frontend-cli | Version: | 1.8β |
Keywords: | test http range do_http partial content | Cc: | |
Launchpad Bug: |
Description
I'm using the same API as tahoe-get.py and I needed to have 'very big files' supported through that API. So I patched do_http() so it has a headers dictionary as parameter in which one can add different options.
I patched also tahoe_get.get() so it supports Partial Content answers (206), and added a 'frange' variable set to None, because I didn't know what CLI option to choose for content retrieval, and did not want to change cli.py. frange shall be a list (or tuple) of two elements :
start = 12 end = 42 frange=[start, end]
Attachments (1)
Change History (2)
Changed at 2010-09-03T16:40:37Z by guyzmo
comment:1 Changed at 2010-09-06T06:55:35Z by zooko
- Keywords test added
Dear guyzmo:
Thank you for the patch! To accept it into trunk, it needs a unit test. I'm not sure, but I think right here would be a good place to test this functionality.
the actual patch