Bottle is a fast, simple and useful one-file WSGI framework. It is not a full-stack framework with a ton of features, but a useful mirco-framework for small web-applications that stays out of your way.
Bottle only depends on the Python Standard Library. If you want to use a HTTP server other than wsgiref.simple_server you may need cherrypy, flup or paste (your choice).
Documentation wiki: http://wiki.github.com/defnull/bottle
Product's homepage
Here are some key features of "Bottle":
· Request dispatching: Map requests to handler-callables using URL-routes
· URL parameters: Use regular expressions /object/(?P[0-9]+) or simplified syntax /object/:id to extract data out of URLs
· WSGI abstraction: Don't worry about cgi and wsgi internals
· Input: request.GET['parameter'] or request.POST['form-field']
· HTTP header: response.header['Content-Type'] = 'text/html'
· Cookie Management: response.COOKIES['session'] = 'new_key'
· Static files: send_file('movie.flv', '/downloads/') with automatic mime-type guessing
· Errors: Throw HTTP errors using abort(404, 'Not here') or subclass HTTPError and use custom error handlers
· Templates: Integrated template language
· Plain simple: Execute python code with %... or use the inline syntax {{...}} for one-line expressions
· No IndentationErrors: Blocks are closed by %end. Indentation is optional.
· Extremely fast: Parses and renders templates 5 to 10 times faster than mako
· Support for Mako-Templates (requires mako)
· HTTP Server: Build in WSGI/HTTP Gateway server (for development and production mode)
· Currently supports wsgiref.simple_server (default), cherrypy, flup, paste and fapws3
Speed optimisations:
· Sendfile: Support for platform-specific high-performance file-transmission facilities, such as the Unix sendfile()
· Depends on wsgi.file_wrapper provided by your WSGI-Server implementation.
· Self optimising routes: Frequently used routes are tested first (optional)
· Fast static routes (single dict lookup)
Requirements:
· Python