export at hope.cz
export at hope.cz
Mon Jan 22 15:22:04 EST 2007
I spent some time to write an input filter hoping that an input filter will help me upload large files without memory errors. But it does NOT help. When I checked Apache error log today I saw: MemoryError, referer: http://127.0.0.1/mod/mptest.py?17644 ( mptest.py is handler I use for uploading .) I use Apache 2.2.4 Mod_python 3.3.0.b Python 2.3.5 Input filter looks like this def inputfilter(filter): if filter.req.method != 'POST': filter.pass_on() return f=open('uploadedfile','ab') s = filter.read() while s: f.write(s) f.flush() filter.write(s) filter.flush() s = filter.read() if s is None: filter.close() f.close() Can anyone help? Will input filter really help or not? Does anyone have any experience with uploading large files( 100 MB and higher)? Thank you help Lad.
|