Skip to content Skip to sidebar Skip to footer

Generic Incoming File Upload Http Request Object For All Python Frameworks

I am working on a SDK that validates and saves incoming multipart/form-data files to disk on the server side. Something like: sdk.upload(httpRequest, destinationPath, validationOpt

Solution 1:

All frameworks implement WSGI protocol https://www.python.org/dev/peps/pep-0333/ . It's the common underlying mechanism and they have built their own convenience functions on the top of that. You can always go back to raw WSGI.

After upload has been processes there is a common framework to store and process the file: Depot http://depot.readthedocs.io/en/latest/

For example you can grab raw WSGI data and generate WebOb Request object out of it in every framework http://webob.org/

Also see Authomatic for inspirations http://peterhudec.github.io/authomatic/

Post a Comment for "Generic Incoming File Upload Http Request Object For All Python Frameworks"