Skip to content
This repository
tag: 1.3a4
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 243 lines (176 sloc) 6.305 kb

The Pyramid Web Application Development Framework

:app:`Pyramid` is a small, fast, down-to-earth Python web application development framework. It is developed as part of the Pylons Project. It is licensed under a BSD-like license.

System Message: ERROR/3 (<string>, line 7); backlink

Unknown interpreted text role "app".

Here is one of the simplest :app:`Pyramid` applications you can make:

System Message: ERROR/3 (<string>, line 12); backlink

Unknown interpreted text role "app".

System Message: ERROR/3 (<string>, line 14)

Unknown directive type "literalinclude".

.. literalinclude:: narr/helloworld.py

When saved to helloworld.py, the above application can be run via:

$ easy_install pyramid
$ python helloworld.py

When you visit http://localhost:8080/hello/world in a browser, you will see the text Hello, world!.

See :ref:`firstapp_chapter` for a full explanation of how this application works. Read the :ref:`html_narrative_documentation` to understand how :app:`Pyramid` is designed to scale from simple applications like this to very large web applications.

System Message: ERROR/3 (<string>, line 26); backlink

Unknown interpreted text role "ref".

System Message: ERROR/3 (<string>, line 26); backlink

Unknown interpreted text role "ref".

System Message: ERROR/3 (<string>, line 26); backlink

Unknown interpreted text role "app".

Front Matter

System Message: ERROR/3 (<string>, line 34)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 1

   copyright.rst
   conventions.rst

"What's New" Documents

System Message: ERROR/3 (<string>, line 43)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 1

   whatsnew-1.3
   whatsnew-1.2
   whatsnew-1.1
   whatsnew-1.0

Narrative documentation

Narrative documentation in chapter form explaining how to use :app:`Pyramid`.

System Message: ERROR/3 (<string>, line 56); backlink

Unknown interpreted text role "app".

System Message: ERROR/3 (<string>, line 59)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 2

   narr/introduction
   narr/install
   narr/firstapp
   narr/configuration
   narr/project
   narr/startup
   narr/router
   narr/urldispatch
   narr/views
   narr/renderers
   narr/templates
   narr/viewconfig
   narr/assets
   narr/webob
   narr/sessions
   narr/events
   narr/environment
   narr/logging
   narr/paste
   narr/commandline
   narr/i18n
   narr/vhosting
   narr/testing
   narr/resources
   narr/muchadoabouttraversal
   narr/traversal
   narr/security
   narr/hybrid
   narr/hooks
   narr/introspector
   narr/extending
   narr/advconfig
   narr/extconfig
   narr/scaffolding
   narr/threadlocals
   narr/zca

Tutorials

Detailed tutorials explaining how to use :app:`Pyramid` to build various types of applications and how to deploy :app:`Pyramid` applications to various platforms.

System Message: ERROR/3 (<string>, line 102); backlink

Unknown interpreted text role "app".

System Message: ERROR/3 (<string>, line 102); backlink

Unknown interpreted text role "app".

System Message: ERROR/3 (<string>, line 106)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 2

   tutorials/wiki2/index.rst
   tutorials/wiki/index.rst
   tutorials/bfg/index.rst
   tutorials/modwsgi/index.rst

Reference Material

Reference material includes documentation for every :app:`Pyramid` API.

System Message: ERROR/3 (<string>, line 117); backlink

Unknown interpreted text role "app".

System Message: ERROR/3 (<string>, line 119)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 2

   api

Detailed Change History

System Message: ERROR/3 (<string>, line 127)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 1

   changes

Design Documentation

System Message: ERROR/3 (<string>, line 135)

Unknown directive type "toctree".

.. toctree::
   :maxdepth: 1

   designdefense

Sample Applications

cluegun is a simple pastebin application based on Rocky Burt's ClueBin. It demonstrates form processing, security, and the use of :term:`ZODB` within a :app:`Pyramid` application. Check this application out via:

System Message: ERROR/3 (<string>, line 143); backlink

Unknown interpreted text role "term".

System Message: ERROR/3 (<string>, line 143); backlink

Unknown interpreted text role "app".
git clone git://github.com/Pylons/cluegun.git

virginia is a very simple dynamic file rendering application. It is willing to render structured text documents, HTML documents, and images from a filesystem directory. An earlier version of this application runs the repoze.org website. Check this application out via:

git clone git://github.com/Pylons/virginia.git

shootout is an example "idea competition" application by Carlos de la Guardia and Lukasz Fidosz. It demonstrates :term:`URL dispatch`, simple authentication, integration with SQLAlchemy and pyramid_simpleform. Check this application out of version control via:

System Message: ERROR/3 (<string>, line 163); backlink

Unknown interpreted text role "term".
git clone git://github.com/Pylons/shootout.git

Older Sample Applications (repoze.bfg)

Note

These applications are for an older version of :app:`Pyramid`, which was named :mod:`repoze.bfg`. They won't work unmodified under Pyramid, but might provide useful clues.

System Message: ERROR/3 (<string>, line 178); backlink

Unknown interpreted text role "app".

System Message: ERROR/3 (<string>, line 178); backlink

Unknown interpreted text role "mod".

bfgsite is the software which runs the bfg.repoze.org website. It demonstrates integration with Trac, and includes several mini-applications such as a pastebin and tutorial engine. Check a buildout for this application out of Subversion via:

svn co http://svn.repoze.org/buildouts/bfgsite/ bfgsite_buildout

KARL is a moderately-sized application (roughly 70K lines of Python code) built on top of :mod:`repoze.bfg` and other Repoze software. It is an open source web system for collaboration, organizational intranets, and knowledge management, It provides facilities for wikis, calendars, manuals, searching, tagging, commenting, and file uploads. See the KARL site for download and installation details.

System Message: ERROR/3 (<string>, line 192); backlink

Unknown interpreted text role "mod".

Support and Development

The Pylons Project web site is the main online source of :app:`Pyramid` support and development information.

System Message: ERROR/3 (<string>, line 203); backlink

Unknown interpreted text role "app".

To report bugs, use the issue tracker.

If you've got questions that aren't answered by this documentation, contact the Pylons-devel maillist or join the #pyramid IRC channel.

Browse and check out tagged and trunk versions of :app:`Pyramid` via the Pyramid GitHub repository. To check out the trunk via git, use this command:

System Message: ERROR/3 (<string>, line 214); backlink

Unknown interpreted text role "app".
git clone git@github.com:Pylons/pyramid.git

To find out how to become a contributor to :app:`Pyramid`, please see the contributor's section of the documentation.

System Message: ERROR/3 (<string>, line 222); backlink

Unknown interpreted text role "app".

Index and Glossary

System Message: ERROR/3 (<string>, line 236)

Unknown directive type "toctree".

.. toctree::
   :hidden:

   glossary
   foreword.rst
   latexindex.rst

Something went wrong with that request. Please try again.