Overview
Otto is an HTTP publisher which uses a routes-like syntax to map URLs to code. It supports object 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 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.4+.
See the documentation for this release.
Changes
1.2 (2009-11-16)
Features
Route matches that come before object mapping are passed on to the mapper on instantiation; these matches are then not passed to the controller.
Backwards incompatibilities
The object mapper takes the place of the traverser; on instantiation it gets the part of the match dictionary that comes before the asterisk.
The empty asterisk is now mapped to the empty string. This does not change the high-level interface.
1.1 (2009-11-12)
Features
The leading slash is now optional in a route path definition.
The Route class now provides the match method.
Backwards incompatibilities
The Publisher.route method was renamed to connect. This method now takes a route object. This change was also applied for the Router class.
1.0 (2009-11-12)
Initial public release.
Metadata
Release files for Otto 1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| Otto-1.2.tar.gz | 69.6 kB | Without provenance | Details for Otto-1.2.tar.gz |
Release files / Otto-1.2.tar.gz
| Download URL | Otto-1.2.tar.gz |
|---|---|
| Size | 69.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d9285c4808e03841bbe77dbac802f6e5f5f1c67befdf3beb4693a9d6a93501ef
|
|
BLAKE2b-256 checksum How to use checksums |
4df0afed4c469cc324afe9f1ab49447c924dca7bb1559d4f7a0596538e999f3b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for Otto 1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.