How would you let your app use a subclass of cgi.FieldStorage? I find this recipe: http://wiki.pylonshq.com/display/pylonscookbook/Hacking+Pylons+for+handling+large+file+upload has very good points, and I thank its author to share them. But I simply couldn't make them work, since passing a non-default base_wsgi_app to PylonsApp in config/middleware.py seems to not be enough: a standard WSGIRequest from paste.wsgiwrappers is still used by Routes.
I worked out this traceback from a post request with multipart/form- data content: File '/usr/lib/python2.5/site-packages/Pylons-0.9.6.1-py2.5.egg/pylons/ error.py', line 245 in respond app_iter = self.application(environ, detect_start_response) File '/usr/lib/python2.5/site-packages/Pylons-0.9.6.1-py2.5.egg/pylons/ wsgiapp.py', line 315 in __call__ return self.app(environ, start_response) File '/usr/lib/python2.5/site-packages/Beaker-0.7.5-py2.5.egg/beaker/ cache.py', line 180 in __call__ return self.app(environ, start_response) File '/usr/lib/python2.5/site-packages/Beaker-0.7.5-py2.5.egg/beaker/ session.py', line 405 in __call__ response = self.wrap_app(environ, session_start_response) File '/usr/lib/python2.5/site-packages/Routes-1.7.1-py2.5.egg/routes/ middleware.py', line 58 in __call__ elif is_form_post(environ) and '_method' in req.POST: File '/usr/lib/python2.5/site-packages/Paste-1.4.2-py2.5.egg/paste/ wsgiwrappers.py', line 213 in POST params = self._POST() that obviously ends up referencing cgi.FieldStorage from standard library. Don't you believe a less hacky solution should be available? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---
