[issue219806] cgi.py uses too much memory on large file uploads

2022-04-10 Thread admin
Change by admin : ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue219806] cgi.py uses too much memory on large file uploads

2022-04-10 Thread admin
Change by admin : -- github: None -> 33418 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

RE: How to handle file uploads with http.server

2010-03-17 Thread Neil Blue
Thanks Gabriel Yep, that looks like the same one. Cheers Neil -Original Message- From: Gabriel Genellina [mailto:gagsl-...@yahoo.com.ar] Sent: 17 March 2010 02:08 To: python-list@python.org Subject: Re: How to handle file uploads with http.server En Thu, 11 Mar 2010 07:30:24 -0300

Re: How to handle file uploads with http.server

2010-03-16 Thread Gabriel Genellina
En Thu, 11 Mar 2010 07:30:24 -0300, Neil Blue neil.b...@biowisdom.com escribió: I have a basic http.server instance running (class HTTPHandler(http.server.BaseHTTPRequestHandler), with python 3.1, and I would like to upload files with multipart forms. def do_POST(self): ctype, pdict

How to handle file uploads with http.server

2010-03-11 Thread Neil Blue
Hello, I have a basic http.server instance running (class HTTPHandler(http.server.BaseHTTPRequestHandler), with python 3.1, and I would like to upload files with multipart forms. def do_POST(self): ctype, pdict = cgi.parse_header(self.headers['Content-Type']) if

CGI, POST, and file uploads

2010-03-03 Thread Mitchell L Model
On Mar 2, 2010, at 4:48 PM, I wrote: Can someone tell me how to upload the contents of a (relatively small) file using an HTML form and CGI in Python 3.1? As far as I can tell from a half-day of experimenting, browsing, and searching the Python issue tracker, this is broken. followed by

CGI, POST, and file uploads

2010-03-02 Thread Mitchell L Model
Can someone tell me how to upload the contents of a (relatively small) file using an HTML form and CGI in Python 3.1? As far as I can tell from a half-day of experimenting, browsing, and searching the Python issue tracker, this is broken. Very simple example: html head /head body

Re: httplib and large file uploads

2006-10-03 Thread John J. Lee
Jesse Noller [EMAIL PROTECTED] 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

httplib and large file uploads

2006-10-02 Thread Jesse Noller
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

Re: httplib and large file uploads

2006-10-02 Thread Eric S. Johansson
Jesse Noller wrote: 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

Re: CGI File Uploads and Progress Bars

2005-09-08 Thread Diez B. Roggisch
So, bottom line: Does anyone know how to get the size of the incoming file data without reading the whole thing into a string? Can I do something with content_header? http://www.faqs.org/rfcs/rfc1867.html It seems that _maybe_ you can use the content-length http header. But it looks as if

RE: CGI File Uploads and Progress Bars

2005-09-08 Thread Robert Brewer
Doug Helm wrote: I'm writing a CGI to handle very large file uploads. I would like to include a progress bar. ...I need to know not only the number of bytes received, but also the total number of incoming bytes. Here's the heart of the code: while afcommon.True: lstrData

CGI File Uploads and Progress Bars

2005-09-07 Thread Doug Helm
Hey, Folks: I'm writing a CGI to handle very large file uploads. I would like to include a progress bar. I think I'm about done. I have code to handle the file upload, and I think I can add an IFrame to my page which posts to check file size (so I can tell how many bytes have been received

Re: File Uploads

2005-03-30 Thread Tim Roberts
Doug Helm [EMAIL PROTECTED] wrote: Hey, Folks: I'm trying to write a very simple file upload CGI. I'm on a Windows server. I *am* using the -u switch to start Python for CGIs, as follows: c:\python\python.exe -u %s %s I *do* have write permissions on the directory I'm trying to write to.

Re: File Uploads

2005-03-28 Thread Doug Helm
Andrew: I'm a dope. You're brilliant. Thank you. That worked splendidly. Doug [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Doug Helm wrote: form = cgi.FieldStorage() if lobjUp.Save('filename', 'SomeFile.jpg'): class BLOB(staticobject.StaticObject): def Save(self,

File Uploads

2005-03-27 Thread Doug Helm
Hey, Folks: I'm trying to write a very simple file upload CGI. I'm on a Windows server. I *am* using the -u switch to start Python for CGIs, as follows: c:\python\python.exe -u %s %s I *do* have write permissions on the directory I'm trying to write to. But, when I click submit, it just

Re: File Uploads

2005-03-27 Thread dimitri pater
Maybe this helps: http://www.voidspace.org.uk/python/cgi.shtml#upload I use it, it works for fine me Maybe it will give you some clues on how to tweak your own script. Dimitri On Sun, 27 Mar 2005 10:32:20 -0700, Doug Helm [EMAIL PROTECTED] wrote: Hey, Folks: I'm trying to write a very

Re: File Uploads

2005-03-27 Thread Doug Helm
Thanks, Dimitri. Yes, I found that same code too and tried it with the exact same result as the code I've uploaded (just hangs). But, OK. You have it working, so it must be a systems issue. Are you also on a Windows IIS web server? Do you have CGI configured the same way (i.e. .py =

Re: File Uploads

2005-03-27 Thread dimitri pater
No, I am on a Linux server. I am not sure how CGI is configured because I do not control the server, I only use it. bye, Dimitri On Sun, 27 Mar 2005 16:19:00 -0700, Doug Helm [EMAIL PROTECTED] wrote: Thanks, Dimitri. Yes, I found that same code too and tried it with the exact same result as

File Uploads -- Windows Server

2005-03-27 Thread Doug Helm
I should have been more clear in my subject line. I was also the poster in the File Uploads topic. I'm not having any luck getting file uploads to work (multi-part HTML form) on a Windows server. I'm using a very close approximation of public domain code that I found. I've tried a couple

Re: File Uploads

2005-03-27 Thread and-google
Doug Helm wrote: form = cgi.FieldStorage() if lobjUp.Save('filename', 'SomeFile.jpg'): class BLOB(staticobject.StaticObject): def Save(self, pstrFormFieldName, pstrFilePathAndName): form = cgi.FieldStorage() You are instantiating cgi.FieldStorage twice. This won't work for POST