httplib and large file uploads

John J. Lee jjl at pobox.com
Tue Oct 3 14:08:02 EDT 2006


"Jesse Noller" <jnoller at gmail.com> writes:

> Hey All,
> 
> I'm working on an script that will generate a file of N size (where N is
> 1k-1gig) in small chunks, in memory (and hash the data on the fly) and pass
> it to an httplib object for upload. I don't want to store the file on the
> disk, or completely in memory at any time. The problem arises after getting
> the http connection (PUT) - and then trying to figure out how to
> iterate/hand the chunks I am generating to the httplib connection's send()
> call. For example (this code does not work as is):
[..]

Define "does not work".


John




More information about the Python-list mailing list