Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
WSGI-compliant HTTP publisher
Python
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
otto
site
CHANGES.rst
Makefile
README.rst
distribute_setup.py
setup.cfg
setup.py

README.rst

Overview

Otto is an HTTP publisher which uses a routes-like syntax to map URLs to code. It supports routing and traversal.

You can use the publisher to write web applications. It was designed with both small and large applications in mind. We have tried to incorporate elements of existing publishers to allow diverse and flexible application patterns while still being in concordance with the :term:`Zen Of Python`.

Here's a variation of a familiar theme:

import otto
import webob
import wsgiref.simple_server

app = otto.Application()

@app.connect("/*path/:name")
def hello_world(request, path=None, name=u'world'):
    return webob.Response(u"An %d-deep hello %s!" % (len(path), name))

wsgiref.simple_server.make_server('', 8080, app).serve_forever()

This release is compatible with Python 2.6+ and Python 3.2+.

See the documentation for this release.

Something went wrong with that request. Please try again.