Skip to main content

Yet another WSGI web app framework

Project description

thruflo.webapp is a WSGI compatible web application framework. It has no test coverage and is no doubt flawed. But it has the advantage of being setup just the way I want it:

  • re.compile based url mapping

  • class instances handling requests with methods that correspond to the HTTP Request’s method, e.g.: def post(self) handles a POST request

  • a webob.Request as self.request

  • return foo as the method of responding, where foo can be a string, a webob.Response, or a list or dict to be returned as JSON

  • [mako templates][] with builtin methods including: * static_url * xsrf_form_html * escape, as well as references to * handler and * request

Or to put it another way:

from thruflo.webapp import web

class Hello(web.RequestHandler):
def get(self):

return ‘hello world’

mapping = [(‘/.*’, MainPage)] application = web.WSGIApplication(mapping)

See [thruflo.webapp.demo][] for a slightly fleshed out usage or read the source code.

[mako templates]: http://www.makotemplates.org [thruflo.webapp.demo]: http://github.com/thruflo/thruflo.webapp/tree/master/src/thruflo/webapp/demo/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

thruflo.webapp-0.1.tar.gz (11.6 kB view details)

Uploaded Source

File details

Details for the file thruflo.webapp-0.1.tar.gz.

File metadata

File hashes

Hashes for thruflo.webapp-0.1.tar.gz
Algorithm Hash digest
SHA256 41ff0c224bb1ea759d63a338dfc777e94478d666029a23aa5dcfd0bfb5d760ee
MD5 109c1ad317abe273cd271a94135e757a
BLAKE2b-256 1a1ad34e26a6b212872c20fc78e64361a1a42d4fb7ed0c9634e726dfb5732368

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page