From 1ffb8e3cc21603b29ccd78152f82cca7f61a09b1 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 16 May 2011 02:11:56 -0400 Subject: - Added API docs for ``pyramid.httpexceptions.abort`` and ``pyramid.httpexceptions.redirect``. - Added "HTTP Exceptions" section to Views narrative chapter including a description of ``pyramid.httpexceptions.abort``; adjusted redirect section to note ``pyramid.httpexceptions.redirect``. - A default exception view for the context ``webob.exc.HTTPException`` (aka ``pyramid.httpexceptions.HTTPException``) is now registered by default. This means that an instance of any exception class imported from ``pyramid.httpexceptions`` (such as ``HTTPFound``) can now be raised from within view code; when raised, this exception view will render the exception to a response. - New functions named ``pyramid.httpexceptions.abort`` and ``pyramid.httpexceptions.redirect`` perform the equivalent of their Pylons brethren when an HTTP exception handler is registered. These functions take advantage of the newly registered exception view for ``webob.exc.HTTPException``. - The Configurator now accepts an additional keyword argument named ``httpexception_view``. By default, this argument is populated with a default exception view function that will be used when an HTTP exception is raised. When ``None`` is passed for this value, an exception view for HTTP exceptions will not be registered. Passing ``None`` returns the behavior of raising an HTTP exception to that of Pyramid 1.0 (the exception will propagate to middleware and to the WSGI server). --- docs/glossary.rst | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index e1e9e76a9..797343e5e 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -618,6 +618,12 @@ Glossary request processing. See :ref:`exception_views` for more information. + HTTP Exception + The set of exception classes defined in :mod:`pyramid.httpexceptions`. + These can be used to generate responses with various status codes when + raised or returned from a :term:`view callable`. See also + :ref:`http_exceptions`. + thread local A thread-local variable is one which is essentially a global variable in terms of how it is accessed and treated, however, each `thread -- cgit v1.2.3 From a7e625785f65c41e5a6dc017b31bd0d74821474e Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Tue, 31 May 2011 14:40:05 -0400 Subject: the canonical import location for HTTP exceptions/responses is now pyramid.response --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 797343e5e..20b9bfd64 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -594,7 +594,7 @@ Glossary Not Found view An :term:`exception view` invoked by :app:`Pyramid` when the - developer explicitly raises a ``pyramid.exceptions.NotFound`` + developer explicitly raises a ``pyramid.response.HTTPNotFound`` exception from within :term:`view` code or :term:`root factory` code, or when the current request doesn't match any :term:`view configuration`. :app:`Pyramid` provides a default @@ -604,7 +604,7 @@ Glossary Forbidden view An :term:`exception view` invoked by :app:`Pyramid` when the developer explicitly raises a - ``pyramid.exceptions.Forbidden`` exception from within + ``pyramid.response.HTTPForbidden`` exception from within :term:`view` code or :term:`root factory` code, or when the :term:`view configuration` and :term:`authorization policy` found for a request disallows a particular view invocation. -- cgit v1.2.3 From df15ed98612e7962e3122da52d8d5f5b9d8882b2 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 4 Jun 2011 18:43:25 -0400 Subject: - It is now possible to control how the Pyramid router calls the WSGI ``start_response`` callable and obtains the WSGI ``app_iter`` based on adapting the response object to the new ``pyramid.interfaces.IResponder`` interface. The default ``IResponder`` uses Pyramid 1.0's logic to do this. To override the responder:: from pyramid.interfaces import IResponder from pyramid.response import Response from myapp import MyResponder config.registry.registerAdapter(MyResponder, (Response,), IResponder, name='') This makes it possible to reuse response object implementations which have, for example, their own ``__call__`` expected to be used as a WSGI application (like ``pyramid.response.Response``), e.g.: class MyResponder(object): def __init__(self, response): """ Obtain a reference to the response """ self.response = response def __call__(self, request, start_response): """ Call start_response and return an app_iter """ app_iter = self.response(request.environ, start_response) return app_iter --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 20b9bfd64..dbab331c1 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -900,5 +900,9 @@ Glossary http://docs.python.org/distutils/index.html for more information. :term:`setuptools` is actually an *extension* of the Distutils. + exception response + A :term:`response` that is generated as the result of a raised exception + being caught by an :term:`exception view`. + -- cgit v1.2.3 From 99edc51a3b05309c7f5d98ff96289ec51b1d7660 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 11 Jun 2011 05:35:27 -0400 Subject: - Pyramid now expects Response objects to have a __call__ method which implements the WSGI application interface instead of the three webob attrs status, headerlist and app_iter. Backwards compatibility exists for code which returns response objects that do not have a __call__. - pyramid.response.Response is no longer an exception (and therefore cannot be raised in order to generate a response). - Changed my mind about moving stuff from pyramid.httpexceptions to pyramid.response. The stuff I moved over has been moved back to pyramid.httpexceptions. --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index dbab331c1..079a069b4 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -594,7 +594,7 @@ Glossary Not Found view An :term:`exception view` invoked by :app:`Pyramid` when the - developer explicitly raises a ``pyramid.response.HTTPNotFound`` + developer explicitly raises a ``pyramid.httpexceptions.HTTPNotFound`` exception from within :term:`view` code or :term:`root factory` code, or when the current request doesn't match any :term:`view configuration`. :app:`Pyramid` provides a default @@ -604,7 +604,7 @@ Glossary Forbidden view An :term:`exception view` invoked by :app:`Pyramid` when the developer explicitly raises a - ``pyramid.response.HTTPForbidden`` exception from within + ``pyramid.httpexceptions.HTTPForbidden`` exception from within :term:`view` code or :term:`root factory` code, or when the :term:`view configuration` and :term:`authorization policy` found for a request disallows a particular view invocation. -- cgit v1.2.3 From d868fff7597c5a05acd1f5c024fc45dde9880413 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 13 Jun 2011 06:17:00 -0400 Subject: - Remove IResponder abstraction in favor of more general IResponse abstraction. - It is now possible to return an arbitrary object from a Pyramid view callable even if a renderer is not used, as long as a suitable adapter to ``pyramid.interfaces.IResponse`` is registered for the type of the returned object. See the section in the Hooks chapter of the documentation entitled "Changing How Pyramid Treats View Responses". - The Pyramid router now, by default, expects response objects returned from view callables to implement the ``pyramid.interfaces.IResponse`` interface. Unlike the Pyramid 1.0 version of this interface, objects which implement IResponse now must define a ``__call__`` method that accepts ``environ`` and ``start_response``, and which returns an ``app_iter`` iterable, among other things. Previously, it was possible to return any object which had the three WebOb ``app_iter``, ``headerlist``, and ``status`` attributes as a response, so this is a backwards incompatibility. It is possible to get backwards compatibility back by registering an adapter to IResponse from the type of object you're now returning from view callables. See the section in the Hooks chapter of the documentation entitled "Changing How Pyramid Treats View Responses". - The ``pyramid.interfaces.IResponse`` interface is now much more extensive. Previously it defined only ``app_iter``, ``status`` and ``headerlist``; now it is basically intended to directly mirror the ``webob.Response`` API, which has many methods and attributes. - Documentation changes to support above. --- docs/glossary.rst | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 079a069b4..d3ba9a545 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -16,12 +16,12 @@ Glossary positional argument, returns a ``WebOb`` compatible request. response - An object that has three attributes: ``app_iter`` (representing an - iterable body), ``headerlist`` (representing the http headers sent - to the user agent), and ``status`` (representing the http status - string sent to the user agent). This is the interface defined for - ``WebOb`` response objects. See :ref:`webob_chapter` for - information about response objects. + An object returned by a :term:`view callable` that represents response + data returned to the requesting user agent. It must implements the + :class:`pyramid.interfaces.IResponse` interface. A response object is + typically an instance of the :class:`pyramid.response.Response` class or + a subclass such as :class:`pyramid.httpexceptions.HTTPFound`. See + :ref:`webob_chapter` for information about response objects. Repoze "Repoze" is essentially a "brand" of software developed by `Agendaless -- cgit v1.2.3 From 6a0602b3ce4d2a6de9dca25d8e0d390796a79267 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 9 Jul 2011 21:12:06 -0400 Subject: request.json -> request.json_body; add some docs for json_body --- docs/glossary.rst | 3 +++ 1 file changed, 3 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index e45317dae..c8943acae 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -506,6 +506,9 @@ Glossary `JavaScript Object Notation `_ is a data serialization format. + jQuery + A popular `Javascript library `_. + renderer A serializer that can be referred to via :term:`view configuration` which converts a non-:term:`Response` return -- cgit v1.2.3 From e005c27ae54f12d5f9579451c1c894a534eb7d48 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Sun, 10 Jul 2011 22:06:51 -0500 Subject: Modified docs to reference webob's new website. --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index c8943acae..0a1c363f4 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -326,7 +326,7 @@ Glossary :term:`ZODB` database. WebOb - `WebOb `_ is a WSGI request/response + `WebOb `_ is a WSGI request/response library created by Ian Bicking. Paste -- cgit v1.2.3 From 4e1199fdb3219ed7ed3635f8ed96fb0cff18abe1 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 11 Jul 2011 04:35:53 -0400 Subject: simplify --- docs/glossary.rst | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 0a1c363f4..3fa2b0261 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -592,8 +592,9 @@ Glossary declaration` required by your application. declarative configuration - The configuration mode in which you use :term:`ZCML` to make a set of - :term:`configuration declaration` statements. See :term:`pyramid_zcml`. + The configuration mode in which you use the combination of + :term:`configuration decorator` decorations and a :term:`scan` to + configure your Pyramid application. Not Found view An :term:`exception view` invoked by :app:`Pyramid` when the -- cgit v1.2.3 From 3cf66ad31a2e76d94421378660174b4058576c10 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 11 Jul 2011 23:36:44 -0400 Subject: bad reference --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 3fa2b0261..bb1ea12ec 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -593,8 +593,8 @@ Glossary declarative configuration The configuration mode in which you use the combination of - :term:`configuration decorator` decorations and a :term:`scan` to - configure your Pyramid application. + :term:`configuration decoration` and a :term:`scan` to configure your + Pyramid application. Not Found view An :term:`exception view` invoked by :app:`Pyramid` when the -- cgit v1.2.3 From f98925f8b05d16114a13c29d03ebc947b6ad084c Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 11 Jul 2011 23:43:12 -0400 Subject: add PyPy --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index bb1ea12ec..cc1d6201d 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -908,3 +908,7 @@ Glossary A :term:`response` that is generated as the result of a raised exception being caught by an :term:`exception view`. + PyPy + PyPy is an "alternative implementation of the Python + language":http://pypy.org/ + -- cgit v1.2.3 From 1f901ab75c55bafc9c233c3c9588cc1bd92d9d66 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Thu, 28 Jul 2011 17:06:29 -0400 Subject: add some edits to the docs for response_adapter decorator; fix renderings --- docs/glossary.rst | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index cc1d6201d..c6705fdc5 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -23,6 +23,11 @@ Glossary a subclass such as :class:`pyramid.httpexceptions.HTTPFound`. See :ref:`webob_chapter` for information about response objects. + response adapter + A callable which accepts an arbitrary object and "converts" it to a + :class:`pyramid.response.Response` object. See :ref:`using_iresponse` + for more information. + Repoze "Repoze" is essentially a "brand" of software developed by `Agendaless Consulting `_ and a set of contributors. The -- cgit v1.2.3 From dc7122f8bb5033d0cd0e95f5adfa66c4499f140e Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 6 Aug 2011 17:41:30 -0400 Subject: add glossary entry for tween --- docs/glossary.rst | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index c6705fdc5..ccb62bbc8 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -917,3 +917,14 @@ Glossary PyPy is an "alternative implementation of the Python language":http://pypy.org/ + tween + A bit of code that sits between the Pyramid router's main request + handling function and the upstream WSGI component that uses + :app:`Pyramid` as its 'app'. A tween may be used by Pyramid framework + extensions, to provide, for example, Pyramid-specific view timing + support bookkeeping code that examines exceptions before they are + returned to the upstream WSGI application. Tweens behave a bit like + :mod:`WSGI` 'middleware' but they have the benefit of running in a + context in which they have access to the Pyramid :term:`application + registry` as well as the Pyramid rendering machinery. + -- cgit v1.2.3 From 05f610e6ed66f8d5aca9d77ae0748feb0c8f8479 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 8 Aug 2011 23:26:59 -0400 Subject: document under and over params --- docs/glossary.rst | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index ccb62bbc8..f0ad81ded 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -920,11 +920,13 @@ Glossary tween A bit of code that sits between the Pyramid router's main request handling function and the upstream WSGI component that uses - :app:`Pyramid` as its 'app'. A tween may be used by Pyramid framework - extensions, to provide, for example, Pyramid-specific view timing - support bookkeeping code that examines exceptions before they are - returned to the upstream WSGI application. Tweens behave a bit like - :mod:`WSGI` 'middleware' but they have the benefit of running in a + :app:`Pyramid` as its 'app'. The word "tween" is a contraction of + "between". A tween may be used by Pyramid framework extensions, to + provide, for example, Pyramid-specific view timing support, bookkeeping + code that examines exceptions before they are returned to the upstream + WSGI application, or a variety of other features. Tweens behave a bit + like :mod:`WSGI` 'middleware' but they have the benefit of running in a context in which they have access to the Pyramid :term:`application - registry` as well as the Pyramid rendering machinery. + registry` as well as the Pyramid rendering machinery. See + :ref:`registering_tweens`. -- cgit v1.2.3 From 93a3b17b93e0f8a8080ae3c486ef5be2cd60562b Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Thu, 11 Aug 2011 13:27:27 -0400 Subject: mod->term --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index f0ad81ded..75bbd2827 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -925,7 +925,7 @@ Glossary provide, for example, Pyramid-specific view timing support, bookkeeping code that examines exceptions before they are returned to the upstream WSGI application, or a variety of other features. Tweens behave a bit - like :mod:`WSGI` 'middleware' but they have the benefit of running in a + like :term:`WSGI` 'middleware' but they have the benefit of running in a context in which they have access to the Pyramid :term:`application registry` as well as the Pyramid rendering machinery. See :ref:`registering_tweens`. -- cgit v1.2.3 From 391402e63c1257ede0069f220ed5a1cca1b94a9b Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 13 Aug 2011 01:00:39 -0400 Subject: - Projects created via a scaffold no longer depend on the ``WebError`` package at all; configuration in the ``production.ini`` file which used to require its ``error_catcher`` middleware has been removed. Configuring error catching / email sending is now the domain of the ``pyramid_exclog`` package (see https://docs.pylonsproject.org/projects/pyramid_exclog/dev/). --- docs/glossary.rst | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 75bbd2827..6e4ca4b70 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -845,11 +845,6 @@ Glossary `WebTest `_ is a package which can help you write functional tests for your WSGI application. - WebError - WSGI middleware which can display debuggable traceback information in - the browser when an exception is raised by a Pyramid application. See - http://pypi.python.org/pypi/WebError . - view mapper A view mapper is a class which implements the :class:`pyramid.interfaces.IViewMapperFactory` interface, which performs @@ -930,3 +925,16 @@ Glossary registry` as well as the Pyramid rendering machinery. See :ref:`registering_tweens`. + pyramid_debugtoolbar + A Pyramid add on which displays a helpful debug toolbar "on top of" HTML + pages rendered by your application, displaying request, routing, and + database information. ``pyramid_debugtoolbar`` is configured into the + ``development.ini`` of all applications which use a Pyramid + :term:`scaffold`. For more information, see + https://docs.pylonsproject.org/projects/pyramid_debugtoolbar/dev/ . + + scaffold + A project template that helps users get started writing a Pyramid + application quickly. Scaffolds are usually used via the ``paster + create`` command. + -- cgit v1.2.3 From bfdbcf4c25e28216060834b648a022045d88146b Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 13 Aug 2011 01:55:45 -0400 Subject: mention pyramid_exclog --- docs/glossary.rst | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 6e4ca4b70..911fbff1a 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -938,3 +938,10 @@ Glossary application quickly. Scaffolds are usually used via the ``paster create`` command. + pyramid_exclog + A package which logs Pyramid application exception (error) information + to a standard Python logger. This add-on is most useful when + used in production applications, because the logger can be configured to + log to a file, to UNIX syslog, to the Windows Event Log, or even to + email. See its `documentation + `_. -- cgit v1.2.3 From d36b566a83addddb80d221aa042b828268f185f2 Mon Sep 17 00:00:00 2001 From: Dylan Jay Date: Thu, 25 Aug 2011 13:05:52 +1000 Subject: use routes in firstapp as they are more familar to most and put hello world on the front page to make grab framework shoppers attention. --- docs/glossary.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 911fbff1a..332006d9d 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -945,3 +945,4 @@ Glossary log to a file, to UNIX syslog, to the Windows Event Log, or even to email. See its `documentation `_. + -- cgit v1.2.3 From 55ce9d632f828d285360c1abee9f56042243cac9 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 28 Aug 2011 22:15:48 -0400 Subject: clean up inappropriate discussions of ZCML --- docs/glossary.rst | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 332006d9d..8bbd9ff7d 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -859,21 +859,15 @@ Glossary pyramid_zcml An add-on package to :app:`Pyramid` which allows applications to be - configured via ZCML. It is available on :term:`PyPI`. If you use - ``pyramid_zcml``, you can use ZCML as an alternative to - :term:`imperative configuration`. + configured via :term:`ZCML`. It is available on :term:`PyPI`. If you + use ``pyramid_zcml``, you can use ZCML as an alternative to + :term:`imperative configuration` or :term:`configuration decoration`. ZCML `Zope Configuration Markup Language `_, an XML dialect used by Zope and :term:`pyramid_zcml` for configuration tasks. - ZCML directive - A ZCML "tag" such as ```` or ````. - - ZCML declaration - The concrete use of a :term:`ZCML directive` within a ZCML file. - pyramid_handlers An add-on package which allows :app:`Pyramid` users to create classes that are analogues of Pylons 1 "controllers". See -- cgit v1.2.3 From 0508684fd039c4b2d6de99beb5e1db4468f712b2 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 4 Sep 2011 15:35:12 -0400 Subject: provide links to implementations from glossary entries where possible. Closes #142 --- docs/glossary.rst | 85 ++++++++++++++++++++++++++++--------------------------- 1 file changed, 43 insertions(+), 42 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 8bbd9ff7d..c5452401c 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -7,13 +7,14 @@ Glossary :sorted: request - A ``WebOb`` request object. See :ref:`webob_chapter` (narrative) - and :ref:`request_module` (API documentation) for information - about request objects. + An object that represents an HTTP request, usually an instance of the + :class:`pyramid.request.Request` class. See :ref:`webob_chapter` + (narrative) and :ref:`request_module` (API documentation) for + information about request objects. request factory - An object which, provided a WSGI environment as a single - positional argument, returns a ``WebOb`` compatible request. + An object which, provided a :term:`WSGI` environment as a single + positional argument, returns a Pyramid-compatible request. response An object returned by a :term:`view callable` that represents response @@ -455,7 +456,7 @@ Glossary :term:`request` object that :app:`Pyramid` generates and manipulates has one or more :term:`interface` objects attached to it. The default interface attached to a request object is - ``pyramid.interfaces.IRequest``. + :class:`pyramid.interfaces.IRequest`. repoze.lemonade Zope2 CMF-like `data structures and helper facilities @@ -569,11 +570,13 @@ Glossary configuration declaration An individual method call made to an instance of a :app:`Pyramid` :term:`Configurator` object which performs an arbitrary action, such as - registering a :term:`view configuration` (via the ``add_view`` method of - the configurator) or :term:`route configuration` (via the ``add_route`` - method of the configurator). A set of configuration declarations is - also implied by the :term:`configuration decoration` detected by a - :term:`scan` of code in a package. + registering a :term:`view configuration` (via the + :meth:`~pyramid.config.Configurator.add_view` method of the + configurator) or :term:`route configuration` (via the + :meth:`~pyramid.config.Configurator.add_route` method of the + configurator). A set of configuration declarations is also implied by + the :term:`configuration decoration` detected by a :term:`scan` of code + in a package. configuration decoration Metadata implying one or more :term:`configuration declaration` @@ -589,7 +592,7 @@ Glossary configurator An object used to do :term:`configuration declaration` within an application. The most common configurator is an instance of the - ``pyramid.config.Configurator`` class. + :class:`pyramid.config.Configurator` class. imperative configuration The configuration mode in which you use Python to call methods on @@ -602,24 +605,22 @@ Glossary Pyramid application. Not Found view - An :term:`exception view` invoked by :app:`Pyramid` when the - developer explicitly raises a ``pyramid.httpexceptions.HTTPNotFound`` - exception from within :term:`view` code or :term:`root factory` - code, or when the current request doesn't match any :term:`view - configuration`. :app:`Pyramid` provides a default - implementation of a not found view; it can be overridden. See + An :term:`exception view` invoked by :app:`Pyramid` when the developer + explicitly raises a :class:`pyramid.httpexceptions.HTTPNotFound` + exception from within :term:`view` code or :term:`root factory` code, + or when the current request doesn't match any :term:`view + configuration`. :app:`Pyramid` provides a default implementation of a + not found view; it can be overridden. See :ref:`changing_the_notfound_view`. Forbidden view - An :term:`exception view` invoked by :app:`Pyramid` when the - developer explicitly raises a - ``pyramid.httpexceptions.HTTPForbidden`` exception from within - :term:`view` code or :term:`root factory` code, or when the - :term:`view configuration` and :term:`authorization policy` + An :term:`exception view` invoked by :app:`Pyramid` when the developer + explicitly raises a :class:`pyramid.httpexceptions.HTTPForbidden` + exception from within :term:`view` code or :term:`root factory` code, + or when the :term:`view configuration` and :term:`authorization policy` found for a request disallows a particular view invocation. - :app:`Pyramid` provides a default implementation of a - forbidden view; it can be overridden. See - :ref:`changing_the_forbidden_view`. + :app:`Pyramid` provides a default implementation of a forbidden view; + it can be overridden. See :ref:`changing_the_forbidden_view`. Exception view An exception view is a :term:`view callable` which may be @@ -713,11 +714,10 @@ Glossary within one or more :term:`translation directory` directories. Translator - A callable which receives a :term:`translation string` and - returns a translated Unicode object for the purposes of - internationalization. A :term:`localizer` supplies a - translator to a :app:`Pyramid` application accessible via its - ``translate`` method. + A callable which receives a :term:`translation string` and returns a + translated Unicode object for the purposes of internationalization. A + :term:`localizer` supplies a translator to a :app:`Pyramid` application + accessible via its :class:`~pyramid.i18n.Localizer.translate` method. Translation Directory A translation directory is a :term:`gettext` translation @@ -805,12 +805,12 @@ Glossary pregenerator A pregenerator is a function associated by a developer with a - :term:`route`. It is called by :func:`pyramid.url.route_url` - in order to adjust the set of arguments passed to it by the user - for special purposes. It will influence the URL returned by - ``route_url``. See - :class:`pyramid.interfaces.IRoutePregenerator` for more - information. + :term:`route`. It is called by + :meth:`~pyramid.request.Request.route_url` in order to adjust the set + of arguments passed to it by the user for special purposes. It will + influence the URL returned by + :meth:`~pyramid.request.Request.route_url`. See + :class:`pyramid.interfaces.IRoutePregenerator` for more information. session A namespace that is valid for some period of continual activity @@ -838,8 +838,9 @@ Glossary Deployment settings Deployment settings are settings passed to the :term:`Configurator` as a ``settings`` argument. These are later accessible via a - ``request.registry.settings`` dictionary. Deployment settings can be - used as global application values. + ``request.registry.settings`` dictionary in views or as + ``config.registry.settings`` in configuration code. Deployment settings + can be used as global application values. WebTest `WebTest `_ is a package which can help @@ -860,7 +861,7 @@ Glossary pyramid_zcml An add-on package to :app:`Pyramid` which allows applications to be configured via :term:`ZCML`. It is available on :term:`PyPI`. If you - use ``pyramid_zcml``, you can use ZCML as an alternative to + use :mod:`pyramid_zcml`, you can use ZCML as an alternative to :term:`imperative configuration` or :term:`configuration decoration`. ZCML @@ -922,8 +923,8 @@ Glossary pyramid_debugtoolbar A Pyramid add on which displays a helpful debug toolbar "on top of" HTML pages rendered by your application, displaying request, routing, and - database information. ``pyramid_debugtoolbar`` is configured into the - ``development.ini`` of all applications which use a Pyramid + database information. :mod:`pyramid_debugtoolbar` is configured into + the ``development.ini`` of all applications which use a Pyramid :term:`scaffold`. For more information, see https://docs.pylonsproject.org/projects/pyramid_debugtoolbar/dev/ . -- cgit v1.2.3 From cfb2b5596b8ef366aeef3bce5b61eafc7a2f175d Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Thu, 6 Oct 2011 03:05:29 -0400 Subject: remove all reference to the paster command-line utility --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index c5452401c..472e591a9 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -930,8 +930,8 @@ Glossary scaffold A project template that helps users get started writing a Pyramid - application quickly. Scaffolds are usually used via the ``paster - create`` command. + application quickly. Scaffolds are usually used via the ``pcreate`` + command. pyramid_exclog A package which logs Pyramid application exception (error) information -- cgit v1.2.3 From f8869cb0664506204b22aa791003a6d5f8ded58c Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Thu, 6 Oct 2011 03:22:35 -0400 Subject: remove stray references to Paste --- docs/glossary.rst | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 472e591a9..fc282b2da 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -95,7 +95,7 @@ Glossary dotted Python name A reference to a Python object by name using a string, in the form - ``path.to.modulename:attributename``. Often used in Paste and + ``path.to.modulename:attributename``. Often used in Pyramid and setuptools configurations. A variant is used in dotted names within configurator method arguments that name objects (such as the "add_view" method's "view" and "context" attributes): the colon (``:``) is not @@ -304,7 +304,7 @@ Glossary application. pipeline - The :term:`Paste` term for a single configuration of a WSGI + The :term:`PasteDeploy` term for a single configuration of a WSGI server, a WSGI application, with a set of middleware in-between. Zope @@ -335,15 +335,11 @@ Glossary `WebOb `_ is a WSGI request/response library created by Ian Bicking. - Paste - `Paste `_ is a WSGI development and - deployment system developed by Ian Bicking. - PasteDeploy `PasteDeploy `_ is a library used by :app:`Pyramid` which makes it possible to configure :term:`WSGI` components together declaratively within an ``.ini`` - file. It was developed by Ian Bicking as part of :term:`Paste`. + file. It was developed by Ian Bicking. Chameleon `chameleon `_ is an attribute -- cgit v1.2.3 From 38369531194f8df0273378b73cb58010d89f3524 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 21 Nov 2011 09:42:35 -0500 Subject: degenshi --- docs/glossary.rst | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index fc282b2da..c98637698 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -342,14 +342,13 @@ Glossary file. It was developed by Ian Bicking. Chameleon - `chameleon `_ is an attribute - language template compiler which supports both the :term:`ZPT` and - :term:`Genshi` templating specifications. It is written and - maintained by Malthe Borch. It has several extensions, such as - the ability to use bracketed (Genshi-style) ``${name}`` syntax, - even within ZPT. It is also much faster than the reference - implementations of both ZPT and Genshi. :app:`Pyramid` offers - Chameleon templating out of the box in ZPT and text flavors. + `chameleon `_ is an attribute language + template compiler which supports the :term:`ZPT` templating + specification. It is written and maintained by Malthe Borch. It has + several extensions, such as the ability to use bracketed (Mako-style) + ``${name}`` syntax. It is also much faster than the reference + implementation of ZPT. :app:`Pyramid` offers Chameleon templating out + of the box in ZPT and text flavors. ZPT The `Zope Page Template `_ -- cgit v1.2.3 From 5edd54f05b05330fa6e899a1bb1650cc7a2df33c Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 27 Nov 2011 04:08:20 -0500 Subject: - The SQLAlchemy Wiki tutorial has been updated. It now uses ``@view_config`` decorators and an explicit database population script. Closes #359. --- docs/glossary.rst | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index c98637698..39933cf4c 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -936,3 +936,8 @@ Glossary email. See its `documentation `_. + console script + A script written to the ``bin`` (on UNIX, or ``Scripts`` on Windows) + directory of a Python installation or virtualenv as the result of + running ``setup.py install`` or ``setup.py develop``. + -- cgit v1.2.3 From f75a3f07b0a5699f99b89d93b4e3a66beea21ac1 Mon Sep 17 00:00:00 2001 From: Chris Davies Date: Thu, 1 Dec 2011 01:57:41 -0500 Subject: https://docs.pylonsproject.org to http://docs.pylonsproject.org as readthedocs.org doesn't support https --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 39933cf4c..0d69fbb0d 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -921,7 +921,7 @@ Glossary database information. :mod:`pyramid_debugtoolbar` is configured into the ``development.ini`` of all applications which use a Pyramid :term:`scaffold`. For more information, see - https://docs.pylonsproject.org/projects/pyramid_debugtoolbar/dev/ . + http://docs.pylonsproject.org/projects/pyramid_debugtoolbar/dev/ . scaffold A project template that helps users get started writing a Pyramid @@ -934,7 +934,7 @@ Glossary used in production applications, because the logger can be configured to log to a file, to UNIX syslog, to the Windows Event Log, or even to email. See its `documentation - `_. + `_. console script A script written to the ``bin`` (on UNIX, or ``Scripts`` on Windows) -- cgit v1.2.3 From c4503bf117e43f780c269e64edbde71fc3d6d72b Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 3 Dec 2011 01:56:17 -0500 Subject: break out 'extending config' into exconfig and add stuff about the action method; move startup and router chapters to earlier in toc --- docs/glossary.rst | 42 +++++++++++++++++++++++++++++++++++++++--- 1 file changed, 39 insertions(+), 3 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 39933cf4c..95ca1f20a 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -563,9 +563,8 @@ Glossary also `PEP 318 `_. configuration declaration - An individual method call made to an instance of a :app:`Pyramid` - :term:`Configurator` object which performs an arbitrary action, such as - registering a :term:`view configuration` (via the + An individual method call made to a :term:`configuration directive`, + such as registering a :term:`view configuration` (via the :meth:`~pyramid.config.Configurator.add_view` method of the configurator) or :term:`route configuration` (via the :meth:`~pyramid.config.Configurator.add_route` method of the @@ -941,3 +940,40 @@ Glossary directory of a Python installation or virtualenv as the result of running ``setup.py install`` or ``setup.py develop``. + introspector + An object with the methods described by + :class:`pyramid.interfaces.IIntrospector` that is available in both + configuration code (for registration) and at runtime (for querying) that + allows a developer to introspect configuration statements and + relationships between those statements. + + conflict resolution + Pyramid attempts to resolve ambiguous configuration statements made by + application developers via automatic conflict resolution. Automatic + conflict resolution is described in + :ref:`automatic_conflict_resolution`. If Pyramid cannot resolve + ambiguous configuration statements, it is possible to manually resolve + them as described in :ref:`manually_resolving_conflicts`. + + configuration directive + A method of the :term:`Configurator` which causes a configuration action + to occur. The method :meth:`pyramid.config.Configurator.add_view` is a + configuration directive, and application developers can add their own + directives as necessary (see :ref:`add_directive`). + + action + Represents a pending configuration statement generated by a call to a + :term:`configuration directive`. The set of pending configuration + actions are processed when :meth:`pyramid.config.Configurator.commit` is + called. + + discriminator + The unique identifier of an :term:`action`. + + introspectable + An object which implements the attributes and methods described in + :class:`pyramid.interfaces.IIntrospectable`. Introspectables are used + by the :term:`introspector` to display configuration information about + a running Pyramid application. An introspectable is associated with a + :term:`action` by virtue of the + :meth:`pyramid.config.Configurator.action` method. -- cgit v1.2.3 From 56df902d0a5bcd29a2b4c3dfafab9a09d6f0c29d Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Thu, 8 Dec 2011 04:26:15 -0500 Subject: - New APIs: ``pyramid.path.AssetResolver`` and ``pyramid.path.DottedNameResolver``. The former can be used to resolve asset specifications, the latter can be used to resolve dotted names to modules or packages. --- docs/glossary.rst | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 399b78cdf..e4de15bd6 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -977,3 +977,9 @@ Glossary a running Pyramid application. An introspectable is associated with a :term:`action` by virtue of the :meth:`pyramid.config.Configurator.action` method. + + asset descriptor + An instance representing an :term:`asset specification` provided by the + :meth:`pyramid.path.AssetResolver.resolve` method. It supports the + methods and attributes documented in + :class:`pyramid.interfaces.IAssetDescriptor`. -- cgit v1.2.3 From c3a36b9b11b9414caabff957e07d4baa2d3367ad Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Wed, 18 Jan 2012 16:38:36 -0500 Subject: untangle some docs about using alternate wsgi servers (divide into 2 sections, one about pserve, the other about waitress vs. others) --- docs/glossary.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index e4de15bd6..8307c0472 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -983,3 +983,15 @@ Glossary :meth:`pyramid.path.AssetResolver.resolve` method. It supports the methods and attributes documented in :class:`pyramid.interfaces.IAssetDescriptor`. + + Waitress + A :term:`WSGI` server that runs on UNIX and Windows under Python 2.6+ + and Python 3.2+. Projects generated via Pyramid scaffolding use + Waitress as a WGSI server. See + http://docs.pylonsproject.org/projects/waitress/en/latest/ for detailed + information. + + Green Unicorn + Aka ``gunicorn``, a fast :term:`WSGI` server that runs on UNIX under + Python 2.5+ (although at the time of this writing does not support + Python 3). See http://gunicorn.org/ for detailed information. -- cgit v1.2.3 From 94c28eb885204f93222dcc0bb3340ae1514b62dd Mon Sep 17 00:00:00 2001 From: Mike Orr Date: Tue, 14 Feb 2012 00:17:46 -0800 Subject: Update Akhet definition. --- docs/glossary.rst | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 8307c0472..60920a73a 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -876,12 +876,11 @@ Glossary on the Jinja2 templating system. Akhet - Akhet is a Pyramid-based development environment which provides a - Pylons-esque scaffold which sports support for :term:`view handler` - application development, :term:`SQLAlchemy` support, :term:`Mako` - templating by default, and other Pylons-like features. See - http://docs.pylonsproject.org/projects/akhet/dev/index.html for more - information. + `Akhet `_ is a + Pyramid library and demo application with a Pylons-like feel. + It's most known for its former application scaffold, which helped + users transition from Pylons and those prefering a more Pylons-like API. + The scaffold has been retired but the demo plays a similar role. Pyramid Cookbook An additional documentation resource for Pyramid which presents topical, -- cgit v1.2.3 From 6751531f0eb874cb70f5f7decc129f592359311c Mon Sep 17 00:00:00 2001 From: Patricio Paez Date: Fri, 13 Apr 2012 06:34:18 -0500 Subject: Fixed wsgi.org URL --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 60920a73a..88598354a 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -290,7 +290,7 @@ Glossary :term:`principal` (or principals) associated with a request. WSGI - `Web Server Gateway Interface `_. This is a + `Web Server Gateway Interface `_. This is a Python standard for connecting web applications to web servers, similar to the concept of Java Servlets. :app:`Pyramid` requires that your application be served as a WSGI application. @@ -299,7 +299,7 @@ Glossary *Middleware* is a :term:`WSGI` concept. It is a WSGI component that acts both as a server and an application. Interesting uses for middleware exist, such as caching, content-transport - encoding, and other functions. See `WSGI.org `_ + encoding, and other functions. See `WSGI.org `_ or `PyPI `_ to find middleware for your application. -- cgit v1.2.3 From 9895440e51c74a46d94a098492f191a3d4b977cb Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sat, 28 Apr 2012 19:31:10 -0700 Subject: expand glossary term for scaffold --- docs/glossary.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 88598354a..45a79326f 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -922,9 +922,9 @@ Glossary http://docs.pylonsproject.org/projects/pyramid_debugtoolbar/dev/ . scaffold - A project template that helps users get started writing a Pyramid - application quickly. Scaffolds are usually used via the ``pcreate`` - command. + A project template that generates some of the major parts of a Pyramid + application and helps users to quickly get started writing larger + applications. Scaffolds are usually used via the ``pcreate`` command. pyramid_exclog A package which logs Pyramid application exception (error) information -- cgit v1.2.3 From 0196b2a06ef66d2e8b33a03cc84373ab84ba44be Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 6 Aug 2012 00:48:29 -0400 Subject: add docs for third-party view predicates --- docs/glossary.rst | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 45a79326f..ba3203f89 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -994,3 +994,9 @@ Glossary Aka ``gunicorn``, a fast :term:`WSGI` server that runs on UNIX under Python 2.5+ (although at the time of this writing does not support Python 3). See http://gunicorn.org/ for detailed information. + + predicate factory + A callable which is used by a third party during the registration of a + route or view predicates to extend the view and route configuration + system. See :ref:`registering_thirdparty_predicates` for more + information. -- cgit v1.2.3 From 95f766bc7c380797c569da464f1f41d12b05bdbe Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 25 Aug 2012 00:10:46 -0400 Subject: Subscriber predicates: - Add ``add_subscriber_predicate`` method to Configurator. - Allow ``add_subscriber`` and ``subscriber`` venusian decorator to accept ``**predicates`` arguments. - Document subscriber predicate feature. - Share more code between view, route, and subscriber related method wrt predicates. --- docs/glossary.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index ba3203f89..34cf1b078 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -997,6 +997,7 @@ Glossary predicate factory A callable which is used by a third party during the registration of a - route or view predicates to extend the view and route configuration + route, view, or subscriber predicates to extend the configuration system. See :ref:`registering_thirdparty_predicates` for more information. + -- cgit v1.2.3 From eab66f3e3f5c6ddbe88c5e632d78263a5c3d7cd4 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 16 Sep 2012 14:36:44 -0400 Subject: update docs to recommend 2.7, add distribute-related instructions for python 3, add windows instructions for python 3, closes #653 --- docs/glossary.rst | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 34cf1b078..2b006da20 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -41,14 +41,20 @@ Glossary setuptools `Setuptools `_ builds on Python's ``distutils`` to provide easier building, - distribution, and installation of libraries and applications. + distribution, and installation of libraries and applications. As of + this writing, setuptools runs under Python 2, but not under Python 3. + You can use :term:`distribute` under Python 3 instead. + + distribute + `Distribute `_ is a fork of + :term:`setuptools` which runs on both Python 2 and Python 3. pkg_resources - A module which ships with :term:`setuptools` that provides an API for - addressing "asset files" within a Python :term:`package`. Asset files - are static files, template files, etc; basically anything - non-Python-source that lives in a Python package can be considered a - asset file. See also `PkgResources + A module which ships with :term:`setuptools` and :term:`distribute` that + provides an API for addressing "asset files" within a Python + :term:`package`. Asset files are static files, template files, etc; + basically anything non-Python-source that lives in a Python package can + be considered a asset file. See also `PkgResources `_ asset @@ -84,7 +90,7 @@ Glossary (Setuptools/distutils terminology). A file representing an installable library or application. Distributions are usually files that have the suffix of ``.egg``, ``.tar.gz``, or ``.zip``. - Distributions are the target of Setuptools commands such as + Distributions are the target of Setuptools-related commands such as ``easy_install``. entry point -- cgit v1.2.3 From 643a83473a6faabd0ff08547a0cbca09e9cdda1c Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Wed, 19 Sep 2012 04:46:01 -0400 Subject: A ``check_csrf`` view predicate was added. For example, you can now do ``config.add_view(someview, check_csrf=True)``. When the predicate is checked, if the ``csrf_token`` value in ``request.params`` matches the csrf token in the request's session, the view will be permitted to execute. Otherwise, it will not be permitted to execute. --- docs/glossary.rst | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 2b006da20..96dd826d1 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -818,9 +818,12 @@ Glossary application. session factory - A callable, which, when called with a single argument named - ``request`` (a :term:`request` object), returns a - :term:`session` object. + A callable, which, when called with a single argument named ``request`` + (a :term:`request` object), returns a :term:`session` object. See + :ref:`using_the_default_session_factory`, + :ref:`using_alternate_session_factories` and + :meth:`pyramid.config.Configurator.set_session_factory` for more + information. Mako `Mako `_ is a template language language -- cgit v1.2.3 From c25a8fd5d2895a117d8eb77162ed8388f0482674 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Fri, 26 Oct 2012 00:32:08 -0400 Subject: - New ``physical_path`` view predicate. If specified, this value should be a string or a tuple representing the physical traversal path of the context found via traversal for this predicate to match as true. For example: ``physical_path='/'`` or ``physical_path='/a/b/c'`` or ``physical_path=('', 'a', 'b', 'c')``. This is not a path prefix match or a regex, it's a whole-path match. It's useful when you want to always potentially show a view when some object is traversed to, but you can't be sure about what kind of object it will be, so you can't use the ``context`` predicate. The individual path elements inbetween slash characters or in tuple elements should be the Unicode representation of the name of the resource and should not be encoded in any way. --- docs/glossary.rst | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 96dd826d1..adcf36f7c 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -481,10 +481,24 @@ Glossary :app:`Pyramid` to form a workflow system. virtual root - A resource object representing the "virtual" root of a request; this - is typically the physical root object (the object returned by the - application root factory) unless :ref:`vhosting_chapter` is in - use. + A resource object representing the "virtual" root of a request; this is + typically the :term:`physical root` object unless :ref:`vhosting_chapter` + is in use. + + physical root + The object returned by the application :term:`root factory`. Unlike the + the :term:`virtual root` of a request, it is not impacted by + :ref:`vhosting_chapter`: it will always be the actual object returned by + the root factory, never a subobject. + + physical path + The path required by a traversal which resolve a :term:`resource` starting + from the :term:`physical root`. For example, the physical path of the + ``abc`` subobject of the physical root object is ``/abc``. Physical paths + can also be specified as tuples where the first element is the empty + string (representing the root), and every other element is a Unicode + object, e.g. ``('', 'abc')``. Physical paths are also sometimes called + "traversal paths". lineage An ordered sequence of objects based on a ":term:`location` -aware" -- cgit v1.2.3 From 043ccddb909327106264d10ed5d413760a51770d Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Wed, 2 Jan 2013 02:22:52 +0200 Subject: eliminate other repeated words --- docs/glossary.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index adcf36f7c..6620552f1 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -486,8 +486,8 @@ Glossary is in use. physical root - The object returned by the application :term:`root factory`. Unlike the - the :term:`virtual root` of a request, it is not impacted by + The object returned by the application :term:`root factory`. + Unlike the :term:`virtual root` of a request, it is not impacted by :ref:`vhosting_chapter`: it will always be the actual object returned by the root factory, never a subobject. @@ -840,7 +840,7 @@ Glossary information. Mako - `Mako `_ is a template language language + `Mako `_ is a template language which refines the familiar ideas of componentized layout and inheritance using Python with Python scoping and calling semantics. -- cgit v1.2.3 From f65e191ed7da0ff97638879cf854c0b1cb505aaa Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Wed, 2 Jan 2013 23:09:40 +0200 Subject: typos --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 6620552f1..5b165db0a 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -921,7 +921,7 @@ Glossary PyPy PyPy is an "alternative implementation of the Python - language":http://pypy.org/ + language": http://pypy.org/ tween A bit of code that sits between the Pyramid router's main request -- cgit v1.2.3 From 29492930e2b04a854371160ddae568ca76536f04 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sat, 19 Jan 2013 11:01:56 +0200 Subject: missing comma --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 5b165db0a..0036d045b 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -689,7 +689,7 @@ Glossary non-C based Python implementations. View Lookup - The act of finding and invoking the "best" :term:`view callable` + The act of finding and invoking the "best" :term:`view callable`, given a :term:`request` and a :term:`context` resource. Resource Location -- cgit v1.2.3 From 3e9b1e566891bce88d63c188b92e223cb22dac2c Mon Sep 17 00:00:00 2001 From: Anton Vlasenko Date: Wed, 30 Jan 2013 22:58:18 +0200 Subject: Updated gunicorn information --- docs/glossary.rst | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 0036d045b..9220e6b5f 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1015,8 +1015,7 @@ Glossary Green Unicorn Aka ``gunicorn``, a fast :term:`WSGI` server that runs on UNIX under - Python 2.5+ (although at the time of this writing does not support - Python 3). See http://gunicorn.org/ for detailed information. + Python 2.6+ or Python 3.1+. See http://gunicorn.org/ for detailed information. predicate factory A callable which is used by a third party during the registration of a -- cgit v1.2.3 From dd1970db763f3114a77ae1c98a3e529562fbfeb5 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sun, 24 Feb 2013 15:03:26 +0200 Subject: virtualenv refers both to the tool and the concept --- docs/glossary.rst | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9220e6b5f..7bc5799f3 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -146,10 +146,9 @@ Glossary request before it returns a :term:`context` resource. virtualenv - An isolated Python environment. Allows you to control which - packages are used on a particular project by cloning your main - Python. `virtualenv `_ - was created by Ian Bicking. + A term referring both to an isolated Python environment, + or `the leading tool `_ that allows one to + create such environments. resource An object representing a node in the :term:`resource tree` of an @@ -959,7 +958,7 @@ Glossary console script A script written to the ``bin`` (on UNIX, or ``Scripts`` on Windows) - directory of a Python installation or virtualenv as the result of + directory of a Python installation or :term:`virtualenv` as the result of running ``setup.py install`` or ``setup.py develop``. introspector -- cgit v1.2.3 From 44b651726b030c106aa5d2ff6ecdd5ba47f6c662 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sat, 16 Feb 2013 13:06:07 +0200 Subject: update link --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9220e6b5f..2d05cde03 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -324,8 +324,8 @@ Glossary `A full-featured Python web framework `_. Pylons - `A lightweight Python web framework `_ and a - predecessor of Pyramid. + `A lightweight Python web framework `_ + and a predecessor of Pyramid. ZODB `Zope Object Database `_, a -- cgit v1.2.3 From eb71e9ef30a0edb43129c24c56885a6c3d61a3a3 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sun, 17 Feb 2013 12:15:52 +0200 Subject: make it clear where the link goes --- docs/glossary.rst | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 2d05cde03..eedd2f34f 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -654,10 +654,9 @@ Glossary `_ used by the application may have a different value for this same "global" variable. :app:`Pyramid` uses a small number of thread local variables, as - described in :ref:`threadlocals_chapter`. See also the `threading.local - documentation - `_ for - more information. + described in :ref:`threadlocals_chapter`. + See also the :class:`stdlib documentation ` + for more information. multidict An ordered dictionary that can have multiple values for each key. Adds -- cgit v1.2.3 From 6ad5fb2a48c9a0c081eb3e2b138752bc8c4e63fb Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Mon, 18 Feb 2013 23:14:16 +0200 Subject: fix links --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index eedd2f34f..d3176325f 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -342,7 +342,7 @@ Glossary library created by Ian Bicking. PasteDeploy - `PasteDeploy `_ is a library used by + `PasteDeploy `_ is a library used by :app:`Pyramid` which makes it possible to configure :term:`WSGI` components together declaratively within an ``.ini`` file. It was developed by Ian Bicking. -- cgit v1.2.3 From cff8573673d919fd0fc3b283bef03923e1db54b5 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Tue, 19 Feb 2013 23:15:36 +0200 Subject: update links --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index d3176325f..75bc126f8 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -684,7 +684,7 @@ Glossary The C implementation of the Python language. This is the reference implementation that most people refer to as simply "Python"; :term:`Jython`, Google's App Engine, and `PyPy - `_ are examples of + `_ are examples of non-C based Python implementations. View Lookup -- cgit v1.2.3 From 0e5cd0f81f5fe053217d13a633ce780ca4477161 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sat, 16 Feb 2013 10:19:01 +0200 Subject: typo --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9220e6b5f..d6adaa787 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -18,7 +18,7 @@ Glossary response An object returned by a :term:`view callable` that represents response - data returned to the requesting user agent. It must implements the + data returned to the requesting user agent. It must implement the :class:`pyramid.interfaces.IResponse` interface. A response object is typically an instance of the :class:`pyramid.response.Response` class or a subclass such as :class:`pyramid.httpexceptions.HTTPFound`. See -- cgit v1.2.3 From 2f4bdefd18073c418ae95fe9e5a8c7b2a9d1130e Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sat, 9 Mar 2013 03:06:17 +0200 Subject: capitalize; add term role --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9220e6b5f..154fb16d6 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -618,13 +618,13 @@ Glossary :term:`configuration decoration` and a :term:`scan` to configure your Pyramid application. - Not Found view + Not Found View An :term:`exception view` invoked by :app:`Pyramid` when the developer explicitly raises a :class:`pyramid.httpexceptions.HTTPNotFound` exception from within :term:`view` code or :term:`root factory` code, or when the current request doesn't match any :term:`view configuration`. :app:`Pyramid` provides a default implementation of a - not found view; it can be overridden. See + Not Found View; it can be overridden. See :ref:`changing_the_notfound_view`. Forbidden view -- cgit v1.2.3 From f73f0e332658fac2583f51247dcd49bd36d63ce4 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Wed, 13 Mar 2013 23:05:17 +0200 Subject: consistency: use $VENV whenever virtualenv binaries are used --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 711994426..ccff2d7db 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -150,6 +150,10 @@ Glossary or `the leading tool `_ that allows one to create such environments. + Note: whenever you encounter commands prefixed with ``$VENV`` (Unix) + or ``%VENV`` (Windows), know that that is the environment variable whose + value is the root of the virtual environment in question. + resource An object representing a node in the :term:`resource tree` of an application. If :mod:`traversal` is used, a resource is an element in -- cgit v1.2.3 From 44c64f2027a6c32a97d7c52970557f3e1aed9b06 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sat, 16 Mar 2013 15:00:58 +0200 Subject: improve description; fix spelling --- docs/glossary.rst | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index ccff2d7db..40c15efdc 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -403,10 +403,9 @@ Glossary dispatching and other application configuration tasks. reStructuredText - A `plain text format `_ - that is the defacto standard for descriptive text shipped in - :term:`distribution` files, and Python docstrings. This - documentation is authored in ReStructuredText format. + A `plain text markup format `_ + that is the defacto standard for documenting Python projects. + The Pyramid documentation is written in reStructuredText. root The object at which :term:`traversal` begins when :app:`Pyramid` -- cgit v1.2.3 From 7c62a15eff2fc4c7cdd76e4b71b3123ff9172825 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Fri, 22 Mar 2013 18:53:23 +0200 Subject: rm unused glossary entry --- docs/glossary.rst | 6 ------ 1 file changed, 6 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 40c15efdc..1b7a5f307 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -334,12 +334,6 @@ Glossary `Zope Object Database `_, a persistent Python object store. - ZEO - `Zope Enterprise Objects - `_ - allows multiple simultaneous processes to access a single - :term:`ZODB` database. - WebOb `WebOb `_ is a WSGI request/response library created by Ian Bicking. -- cgit v1.2.3 From 00d6b8d9c7c389582d1537bfafe04e549651af52 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Mon, 25 Mar 2013 12:00:38 +0200 Subject: improve description; fix link --- docs/glossary.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 1b7a5f307..1673e2c41 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -901,9 +901,9 @@ Glossary The scaffold has been retired but the demo plays a similar role. Pyramid Cookbook - An additional documentation resource for Pyramid which presents topical, - practical usages of Pyramid available via - http://docs.pylonsproject.org/ . + Additional documentation for Pyramid which presents topical, + practical uses of Pyramid: + http://docs.pylonsproject.org/projects/pyramid_cookbook/en/latest. distutils The standard system for packaging and distributing Python packages. See -- cgit v1.2.3 From 4b43baa10d86d27775081d12e561628bc398b96d Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Thu, 28 Mar 2013 20:10:35 +0200 Subject: fix link --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 1673e2c41..3a732e853 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -932,12 +932,12 @@ Glossary :ref:`registering_tweens`. pyramid_debugtoolbar - A Pyramid add on which displays a helpful debug toolbar "on top of" HTML + A Pyramid add-on which displays a helpful debug toolbar "on top of" HTML pages rendered by your application, displaying request, routing, and database information. :mod:`pyramid_debugtoolbar` is configured into the ``development.ini`` of all applications which use a Pyramid :term:`scaffold`. For more information, see - http://docs.pylonsproject.org/projects/pyramid_debugtoolbar/dev/ . + http://docs.pylonsproject.org/projects/pyramid_debugtoolbar/en/latest/. scaffold A project template that generates some of the major parts of a Pyramid -- cgit v1.2.3 From 37607c3a9382de7c3757799791a91b80e2d9888d Mon Sep 17 00:00:00 2001 From: Catalin Iacob Date: Sun, 31 Mar 2013 14:33:24 +0200 Subject: Consistently link middleware term to the glossary --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 3a732e853..241f951d6 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -314,7 +314,7 @@ Glossary pipeline The :term:`PasteDeploy` term for a single configuration of a WSGI - server, a WSGI application, with a set of middleware in-between. + server, a WSGI application, with a set of :term:`middleware` in-between. Zope `The Z Object Publishing Framework `_, a @@ -926,7 +926,7 @@ Glossary provide, for example, Pyramid-specific view timing support, bookkeeping code that examines exceptions before they are returned to the upstream WSGI application, or a variety of other features. Tweens behave a bit - like :term:`WSGI` 'middleware' but they have the benefit of running in a + like :term:`WSGI` :term:`middleware` but they have the benefit of running in a context in which they have access to the Pyramid :term:`application registry` as well as the Pyramid rendering machinery. See :ref:`registering_tweens`. -- cgit v1.2.3 From 125ea45ae864a5513e6d83fdded6ceea9516b578 Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sat, 6 Apr 2013 07:07:37 +0200 Subject: fix some cross-references Also, pyramid_zcml is cross-referenced, so add it to intersphinx_mapping dict. --- docs/glossary.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 241f951d6..b6bd35ffe 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -156,9 +156,9 @@ Glossary resource An object representing a node in the :term:`resource tree` of an - application. If :mod:`traversal` is used, a resource is an element in + application. If :term:`traversal` is used, a resource is an element in the resource tree traversed by the system. When traversal is used, a - resource becomes the :term:`context` of a :term:`view`. If :mod:`url + resource becomes the :term:`context` of a :term:`view`. If :term:`url dispatch` is used, a single resource is generated for each request and is used as the context resource of a view. -- cgit v1.2.3 From 452005b6a96b6096b65ce63cb91574197cc9718c Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Sun, 28 Apr 2013 19:37:48 +0200 Subject: use a cross-ref instead of a raw link --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index b6bd35ffe..abc37c7f8 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -698,7 +698,7 @@ Glossary :app:`Pyramid` runs on GAE. Venusian - `Venusian `_ is a library which + :ref:`Venusian` is a library which allows framework authors to defer decorator actions. Instead of taking actions when a function (or class) decorator is executed at import time, the action usually taken by the decorator is -- cgit v1.2.3 From d559afa1b3fabe2733e97c64df4370cc12f33ce0 Mon Sep 17 00:00:00 2001 From: Paul Everitt Date: Tue, 6 Aug 2013 15:23:51 -0400 Subject: Up through JSON. --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index abc37c7f8..8ade889a3 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1018,3 +1018,7 @@ Glossary system. See :ref:`registering_thirdparty_predicates` for more information. + add-on + A Python :term:`distribution` that uses Pyramid's extensibility + to plug into a Pyramid application and provide extra, + configurable services. \ No newline at end of file -- cgit v1.2.3 From c6601f77f91dc933ca429d1448f4c6b27857b608 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 22:52:54 -0400 Subject: - The ``renderer_globals_factory`` argument to the ``pyramid.config.Configurator` constructor and its ``setup_registry`` method has been removed. The ``set_renderer_globals_factory`` method of ``pyramid.config.Configurator`` has also been removed. The (internal) ``pyramid.interfaces.IRendererGlobals`` interface was also removed. These arguments, methods and interfaces had been deprecated since 1.1. Use a ``BeforeRender`` event subscriber as documented in the "Hooks" chapter of the Pyramid narrative documentation instead of providing renderer globals values to the configurator. --- docs/glossary.rst | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 8ade889a3..7dc69c7c4 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -798,9 +798,8 @@ Glossary :term:`Internationalization`. renderer globals - Values injected as names into a renderer based on application - policy. See :ref:`adding_renderer_globals` for more - information. + Values injected as names into a renderer by a + :class:`pyramid.event.BeforeRender` event. response callback A user-defined callback executed by the :term:`router` at a @@ -1021,4 +1020,4 @@ Glossary add-on A Python :term:`distribution` that uses Pyramid's extensibility to plug into a Pyramid application and provide extra, - configurable services. \ No newline at end of file + configurable services. -- cgit v1.2.3 From ab2fedf7adaec0a56a69beed35312c88d7961c6c Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Wed, 2 Oct 2013 17:47:17 -0400 Subject: fix the docs build and get rid of stray references to Beaker --- docs/glossary.rst | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 7dc69c7c4..398f945a4 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1009,7 +1009,8 @@ Glossary Green Unicorn Aka ``gunicorn``, a fast :term:`WSGI` server that runs on UNIX under - Python 2.6+ or Python 3.1+. See http://gunicorn.org/ for detailed information. + Python 2.6+ or Python 3.1+. See http://gunicorn.org/ for detailed + information. predicate factory A callable which is used by a third party during the registration of a @@ -1021,3 +1022,9 @@ Glossary A Python :term:`distribution` that uses Pyramid's extensibility to plug into a Pyramid application and provide extra, configurable services. + + pyramid_redis_sessions + A package by Eric Rasmussen which allows you to store Pyramid session + data in a Redis database. See + https://pypi.python.org/pypi/pyramid_redis_sessions for more information. + -- cgit v1.2.3 From 96188ac4b74cb1e67cb95afdb9519ecd8934d688 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Wed, 2 Oct 2013 18:56:56 -0400 Subject: rearrange the fix --- docs/glossary.rst | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 398f945a4..406b81778 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -505,15 +505,20 @@ Glossary available as its ``__parent__`` attribute. root factory - The "root factory" of a :app:`Pyramid` application is called - on every request sent to the application. The root factory - returns the traversal root of an application. It is - conventionally named ``get_root``. An application may supply a - root factory to :app:`Pyramid` during the construction of a - :term:`Configurator`. If a root factory is not supplied, the - application uses a default root object. Use of the default root - object is useful in application which use :term:`URL dispatch` for - all URL-to-view code mappings. + The "root factory" of a :app:`Pyramid` application is called on every + request sent to the application. The root factory returns the traversal + root of an application. It is conventionally named ``get_root``. An + application may supply a root factory to :app:`Pyramid` during the + construction of a :term:`Configurator`. If a root factory is not + supplied, the application creates a default root object using the + :term:`default root factory`. + + default root factory + If an application does not register a :term:`root factory` at Pyramid + configuration time, a *default* root factory is used to created the + default root object. Use of the default root object is useful in + application which use :term:`URL dispatch` for all URL-to-view code + mappings, and does not (knowingly) use traversal otherwise. SQLAlchemy `SQLAlchemy `_ is an object -- cgit v1.2.3 From 2033eeb3602f330930585678aac926749b9c22f7 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Mon, 10 Feb 2014 03:22:33 -0600 Subject: - Garden PR #1121 --- docs/glossary.rst | 66 +++++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 50 insertions(+), 16 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 406b81778..0e340491b 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -54,8 +54,12 @@ Glossary provides an API for addressing "asset files" within a Python :term:`package`. Asset files are static files, template files, etc; basically anything non-Python-source that lives in a Python package can - be considered a asset file. See also `PkgResources - `_ + be considered a asset file. + + .. seealso:: + + See also `PkgResources + `_. asset Any file contained within a Python :term:`package` which is *not* @@ -242,7 +246,11 @@ Glossary be effectively amended with a ``permission`` argument that will require that the executing user possess the default permission in order to successfully execute the associated :term:`view - callable` See also :ref:`setting_a_default_permission`. + callable`. + + .. seealso:: + + See also :ref:`setting_a_default_permission`. ACE An *access control entry*. An access control entry is one element @@ -380,7 +388,11 @@ Glossary route A single pattern matched by the :term:`url dispatch` subsystem, which generally resolves to a :term:`root factory` (and then - ultimately a :term:`view`). See also :term:`url dispatch`. + ultimately a :term:`view`). + + .. seealso:: + + See also :term:`url dispatch`. route configuration Route configuration is the act of associating request parameters with a @@ -580,8 +592,11 @@ Glossary A wrapper around a Python function or class which accepts the function or class as its first argument and which returns an arbitrary object. :app:`Pyramid` provides several decorators, - used for configuration and return value modification purposes. See - also `PEP 318 `_. + used for configuration and return value modification purposes. + + .. seealso:: + + See also `PEP 318 `_. configuration declaration An individual method call made to a :term:`configuration directive`, @@ -646,8 +661,11 @@ Glossary HTTP Exception The set of exception classes defined in :mod:`pyramid.httpexceptions`. These can be used to generate responses with various status codes when - raised or returned from a :term:`view callable`. See also - :ref:`http_exceptions`. + raised or returned from a :term:`view callable`. + + .. seealso:: + + See also :ref:`http_exceptions`. thread local A thread-local variable is one which is essentially a global variable @@ -656,8 +674,11 @@ Glossary application may have a different value for this same "global" variable. :app:`Pyramid` uses a small number of thread local variables, as described in :ref:`threadlocals_chapter`. - See also the :class:`stdlib documentation ` - for more information. + + .. seealso:: + + See also the :class:`stdlib documentation ` + for more information. multidict An ordered dictionary that can have multiple values for each key. Adds @@ -671,7 +692,11 @@ Glossary Agendaless Consulting A consulting organization formed by Paul Everitt, Tres Seaver, - and Chris McDonough. See also http://agendaless.com . + and Chris McDonough. + + .. seealso:: + + See also `Agendaless Consulting `_. Jython A `Python implementation `_ written for @@ -792,15 +817,21 @@ Glossary The act of creating software with a user interface that can potentially be displayed in more than one language or cultural context. Often shortened to "i18n" (because the word - "internationalization" is I, 18 letters, then N). See also: - :term:`Localization`. + "internationalization" is I, 18 letters, then N). + + .. seealso:: + + See also :term:`Localization`. Localization The process of displaying the user interface of an internationalized application in a particular language or cultural context. Often shortened to "l10" (because the word - "localization" is L, 10 letters, then N). See also: - :term:`Internationalization`. + "localization" is L, 10 letters, then N). + + .. seealso:: + + See also :term:`Internationalization`. renderer globals Values injected as names into a renderer by a @@ -809,7 +840,10 @@ Glossary response callback A user-defined callback executed by the :term:`router` at a point after a :term:`response` object is successfully created. - See :ref:`using_response_callbacks`. + + .. seealso:: + + See also :ref:`using_response_callbacks`. finished callback A user-defined callback executed by the :term:`router` -- cgit v1.2.3 From 98a99d726f8892376f69fba0fa6b99752972f1c8 Mon Sep 17 00:00:00 2001 From: Wichert Akkerman Date: Tue, 8 Apr 2014 20:11:37 +0200 Subject: Update Lingua glossary item. --- docs/glossary.rst | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 0e340491b..2cc461a77 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -801,8 +801,9 @@ Glossary application. Lingua - A package by Wichert Akkerman which provides :term:`Babel` message - extractors for Python source files and Chameleon ZPT template files. + A package by Wichert Akkerman which provides the ``pot-create`` + command to extract translateable messages from Python sources + and Chameleon ZPT template files. Message Identifier A string used as a translation lookup key during localization. -- cgit v1.2.3 From 7096d92efd27b96ae48c798a207905f4c38b13c5 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sat, 3 May 2014 22:34:53 -0700 Subject: - spelling --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 2cc461a77..deb4c1c8b 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -936,7 +936,7 @@ Glossary `Akhet `_ is a Pyramid library and demo application with a Pylons-like feel. It's most known for its former application scaffold, which helped - users transition from Pylons and those prefering a more Pylons-like API. + users transition from Pylons and those preferring a more Pylons-like API. The scaffold has been retired but the demo plays a similar role. Pyramid Cookbook -- cgit v1.2.3 From 5cf18393fbe9084e4b079a1136ed5de46ad89969 Mon Sep 17 00:00:00 2001 From: "Karl O. Pinc" Date: Tue, 12 Aug 2014 20:49:11 -0500 Subject: Docs: Introduce the concept of "userid" into the glossary. --- docs/glossary.rst | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index deb4c1c8b..eb57f3d0d 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -286,13 +286,23 @@ Glossary :term:`authorization policy`. principal - A *principal* is a string or unicode object representing a userid - or a group id. It is provided by an :term:`authentication - policy`. For example, if a user had the user id "bob", and Bob - was part of two groups named "group foo" and "group bar", the - request might have information attached to it that would - indicate that Bob was represented by three principals: "bob", - "group foo" and "group bar". + A *principal* is a string or unicode object representing an + entity, typically a user or group, having zero or more + :term:`permissions `. Principals are provided by an + :term:`authentication policy`. For example, if a user had the + user id "bob", and Bob was part of two groups named "group foo" + and "group bar", the request might have information attached to + it that would indicate that Bob was represented by three + principals: "bob", "group foo" and "group bar". + + userid + A *userid* is a a string or unicode object used to identify and + authenticate a real-world user, often a person. A userid is + supplied to an :term:`authentication policy` in order to discover + the user's :term:`principals `. The default behavior + of the authentication policies :app:`Pyramid` provides is to + return the user's userid as one of the user's principals, but a + userid need not be a principal. authorization policy An authorization policy in :app:`Pyramid` terms is a bit of -- cgit v1.2.3 From fe83c6bfdab16818cb434d95a09bd6510b43aa24 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Wed, 13 Aug 2014 10:48:22 -0500 Subject: some tweaks to the usage of userid in the docs --- docs/glossary.rst | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index eb57f3d0d..ef207a4bb 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -287,22 +287,21 @@ Glossary principal A *principal* is a string or unicode object representing an - entity, typically a user or group, having zero or more - :term:`permissions `. Principals are provided by an + entity, typically a user or group. Principals are provided by an :term:`authentication policy`. For example, if a user had the - user id "bob", and Bob was part of two groups named "group foo" + :term:`userid` `"bob"`, and was part of two groups named `"group foo"` and "group bar", the request might have information attached to it that would indicate that Bob was represented by three - principals: "bob", "group foo" and "group bar". + principals: `"bob"`, `"group foo"` and `"group bar"`. userid - A *userid* is a a string or unicode object used to identify and - authenticate a real-world user, often a person. A userid is + A *userid* is a string or unicode object used to identify and + authenticate a real-world user (or client). A userid is supplied to an :term:`authentication policy` in order to discover the user's :term:`principals `. The default behavior of the authentication policies :app:`Pyramid` provides is to - return the user's userid as one of the user's principals, but a - userid need not be a principal. + return the user's userid as a principal, but this is not strictly + necessary in custom policies that define their principals differently. authorization policy An authorization policy in :app:`Pyramid` terms is a bit of -- cgit v1.2.3 From 2a079b541b7c917d2be360ea0c4bd0d1ac6a4556 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sun, 9 Nov 2014 11:56:54 -0800 Subject: - add Translation Context term to Glossary to allow Sphinx to build docs, in reference to a recent update in the docstrings to the package translationstring https://github.com/Pylons/translationstring/blame/master/translationstring/__init__.py#L50 --- docs/glossary.rst | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index deb4c1c8b..ef7e9a9ae 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -749,9 +749,16 @@ Glossary made. For example the word "java" might be translated differently if the translation domain is "programming-languages" than would be if the translation domain was "coffee". A - translation domain is represnted by a collection of ``.mo`` files + translation domain is represented by a collection of ``.mo`` files within one or more :term:`translation directory` directories. + Translation Context + A string representing the "context" in which a translation was + made within a given :term:`translation domain`. See the gettext + documentation, `11.2.5 Using contexts for solving ambiguities + `_ + for more information. + Translator A callable which receives a :term:`translation string` and returns a translated Unicode object for the purposes of internationalization. A -- cgit v1.2.3 From e8a666655b5365a0adde32f2bd387b0d42690384 Mon Sep 17 00:00:00 2001 From: John Anderson Date: Sat, 27 Dec 2014 00:23:18 -0800 Subject: basic docs cleanup --- docs/glossary.rst | 3 +++ 1 file changed, 3 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 01300a0be..05ff7c114 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -16,6 +16,9 @@ Glossary An object which, provided a :term:`WSGI` environment as a single positional argument, returns a Pyramid-compatible request. + response factory + An object which returns a Pyramid-compatible response. + response An object returned by a :term:`view callable` that represents response data returned to the requesting user agent. It must implement the -- cgit v1.2.3 From 32cb805132e8149a276a8c65fdfa961384e8254e Mon Sep 17 00:00:00 2001 From: John Anderson Date: Thu, 1 Jan 2015 15:03:56 -0800 Subject: Mkae the response factory a factory that takes a request --- docs/glossary.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 05ff7c114..38133f68f 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -17,7 +17,8 @@ Glossary positional argument, returns a Pyramid-compatible request. response factory - An object which returns a Pyramid-compatible response. + An object which, provied a :term:`request` as a single positional + argument, returns a Pyramid-compatible response. response An object returned by a :term:`view callable` that represents response -- cgit v1.2.3 From ff01cdf0e392eb4e7926970a0cdee75663edb431 Mon Sep 17 00:00:00 2001 From: John Anderson Date: Thu, 1 Jan 2015 15:10:55 -0800 Subject: Fix typo --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 38133f68f..911c22075 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -17,7 +17,7 @@ Glossary positional argument, returns a Pyramid-compatible request. response factory - An object which, provied a :term:`request` as a single positional + An object which, provided a :term:`request` as a single positional argument, returns a Pyramid-compatible response. response -- cgit v1.2.3 From da5f5f9ea02c2c9830c7ae016547d2bedd0e0171 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Sat, 7 Feb 2015 02:38:54 -0600 Subject: move the IResponseFactory into the public api --- docs/glossary.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 911c22075..9c0ea8598 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -18,7 +18,8 @@ Glossary response factory An object which, provided a :term:`request` as a single positional - argument, returns a Pyramid-compatible response. + argument, returns a Pyramid-compatible response. See + :class:`pyramid.interfaces.IResponseFactory`. response An object returned by a :term:`view callable` that represents response -- cgit v1.2.3 From 31f3d86d3bf5db3c4aa5085c7b7a4d6396f29931 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Thu, 12 Nov 2015 00:55:38 -0600 Subject: complete cache buster docs using manifest example --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9c0ea8598..b4bb36421 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1089,3 +1089,7 @@ Glossary data in a Redis database. See https://pypi.python.org/pypi/pyramid_redis_sessions for more information. + cache busting + A technique used when serving a cacheable static asset in order to force + a client to query the new version of the asset. See :ref:`cache_busting` + for more information. -- cgit v1.2.3 From 6f4e97603c2562914567a85bf18187299c3b543b Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Thu, 12 Nov 2015 20:04:28 -0600 Subject: Revert "fix/remove-default-cachebusters" This reverts commit 7410250313f893e5952bb2697324a4d4e3d47d22. This reverts commit cbec33b898efffbfa6acaf91cae45ec0daed4d7a. This reverts commit 345ca3052c395545b90fef9104a16eed5ab051a5, reversing changes made to 47162533af84bb8d26db6d1c9ba1e63d70e9070f. --- docs/glossary.rst | 4 ---- 1 file changed, 4 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index b4bb36421..9c0ea8598 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1089,7 +1089,3 @@ Glossary data in a Redis database. See https://pypi.python.org/pypi/pyramid_redis_sessions for more information. - cache busting - A technique used when serving a cacheable static asset in order to force - a client to query the new version of the asset. See :ref:`cache_busting` - for more information. -- cgit v1.2.3 From 3a41196208c7fd78cfb177bb5105c6a702436b78 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Tue, 20 Oct 2015 00:32:14 -0500 Subject: update cache buster prose and add ManifestCacheBuster redux of #2013 --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9c0ea8598..b4bb36421 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1089,3 +1089,7 @@ Glossary data in a Redis database. See https://pypi.python.org/pypi/pyramid_redis_sessions for more information. + cache busting + A technique used when serving a cacheable static asset in order to force + a client to query the new version of the asset. See :ref:`cache_busting` + for more information. -- cgit v1.2.3 From b7057f3dcac875d71916d6807d157ff6f3ede662 Mon Sep 17 00:00:00 2001 From: Bastien Date: Sat, 26 Dec 2015 14:33:23 -0800 Subject: Update glossary.rst fixed typo (cherry picked from commit 0a5c9a2) --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index b4bb36421..60e861597 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -273,7 +273,7 @@ Glossary (Allow, 'bob', 'read'), (Deny, 'fred', 'write')]``. If an ACL is attached to a resource instance, and that resource is findable via the context resource, it will be consulted any active security policy to - determine wither a particular request can be fulfilled given the + determine whether a particular request can be fulfilled given the :term:`authentication` information in the request. authentication -- cgit v1.2.3 From 6860b286dcf604eaef4940ab8e8e10e8cbcc1a58 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Fri, 8 Jan 2016 06:22:05 -0800 Subject: update glossary with cookbook rst syntax. closes #2215 --- docs/glossary.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 60e861597..60f03f000 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -960,10 +960,10 @@ Glossary users transition from Pylons and those preferring a more Pylons-like API. The scaffold has been retired but the demo plays a similar role. - Pyramid Cookbook - Additional documentation for Pyramid which presents topical, - practical uses of Pyramid: - http://docs.pylonsproject.org/projects/pyramid_cookbook/en/latest. + Pyramid Community Cookbook + Additional, community-based documentation for Pyramid which presents + topical, practical uses of Pyramid: + :ref:`Pyramid Community Cookbook ` distutils The standard system for packaging and distributing Python packages. See -- cgit v1.2.3 From 99098dddf8baa23727f410f2fa6b543c0641fa21 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Fri, 8 Jan 2016 06:32:19 -0800 Subject: revert glossary entry name for tox on 3.5. I'll get this on a massive update on another pass. See https://github.com/Pylons/pyramid_cookbook/issues/155 --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 60f03f000..82423a59d 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -960,7 +960,7 @@ Glossary users transition from Pylons and those preferring a more Pylons-like API. The scaffold has been retired but the demo plays a similar role. - Pyramid Community Cookbook + Pyramid Cookbook Additional, community-based documentation for Pyramid which presents topical, practical uses of Pyramid: :ref:`Pyramid Community Cookbook ` -- cgit v1.2.3 From 34515f33b3e391dd1c0c727bf5ef4af586b57889 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Thu, 14 Jan 2016 02:55:04 -0800 Subject: Rename Cookbook to Pyramid Community Cookbook - use .rst intersphinx labels for pages instead of broken URLs --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 82423a59d..60f03f000 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -960,7 +960,7 @@ Glossary users transition from Pylons and those preferring a more Pylons-like API. The scaffold has been retired but the demo plays a similar role. - Pyramid Cookbook + Pyramid Community Cookbook Additional, community-based documentation for Pyramid which presents topical, practical uses of Pyramid: :ref:`Pyramid Community Cookbook ` -- cgit v1.2.3 From 1cb1104f983ca92695ca24cb79ad6bfbb432aad3 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sat, 30 Jan 2016 00:31:01 -0800 Subject: clean up principal and userid glossary entries for grammar, rst syntax --- docs/glossary.rst | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 60f03f000..2683ff369 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -234,7 +234,7 @@ Glossary object *location-aware*. permission - A string or unicode object that represents an action being taken against + A string or Unicode object that represents an action being taken against a :term:`context` resource. A permission is associated with a view name and a resource type by the developer. Resources are decorated with security declarations (e.g. an :term:`ACL`), which reference these @@ -291,22 +291,22 @@ Glossary :term:`authorization policy`. principal - A *principal* is a string or unicode object representing an - entity, typically a user or group. Principals are provided by an - :term:`authentication policy`. For example, if a user had the - :term:`userid` `"bob"`, and was part of two groups named `"group foo"` - and "group bar", the request might have information attached to - it that would indicate that Bob was represented by three - principals: `"bob"`, `"group foo"` and `"group bar"`. + A *principal* is a string or Unicode object representing an entity, + typically a user or group. Principals are provided by an + :term:`authentication policy`. For example, if a user has the + :term:`userid` `bob`, and is a member of two groups named `group foo` and + `group bar`, then the request might have information attached to it + indicating that Bob was represented by three principals: `bob`, `group + foo` and `group bar`. userid - A *userid* is a string or unicode object used to identify and - authenticate a real-world user (or client). A userid is - supplied to an :term:`authentication policy` in order to discover - the user's :term:`principals `. The default behavior - of the authentication policies :app:`Pyramid` provides is to - return the user's userid as a principal, but this is not strictly - necessary in custom policies that define their principals differently. + A *userid* is a string or Unicode object used to identify and authenticate + a real-world user or client. A userid is supplied to an + :term:`authentication policy` in order to discover the user's + :term:`principals `. In the authentication policies which + :app:`Pyramid` provides, the default behavior returns the user's userid as + a principal, but this is not strictly necessary in custom policies that + define their principals differently. authorization policy An authorization policy in :app:`Pyramid` terms is a bit of -- cgit v1.2.3 From 8d212aac349c381fa20c2c8927acdaf4873e394e Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sat, 20 Feb 2016 19:09:34 -0800 Subject: fix links for babel and chameleon --- docs/glossary.rst | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 2683ff369..bbc86db41 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -367,13 +367,13 @@ Glossary file. It was developed by Ian Bicking. Chameleon - `chameleon `_ is an attribute language - template compiler which supports the :term:`ZPT` templating - specification. It is written and maintained by Malthe Borch. It has - several extensions, such as the ability to use bracketed (Mako-style) - ``${name}`` syntax. It is also much faster than the reference - implementation of ZPT. :app:`Pyramid` offers Chameleon templating out - of the box in ZPT and text flavors. + `chameleon `_ is an + attribute language template compiler which supports the :term:`ZPT` + templating specification. It is written and maintained by Malthe Borch. It + has several extensions, such as the ability to use bracketed (Mako-style) + ``${name}`` syntax. It is also much faster than the reference + implementation of ZPT. :app:`Pyramid` offers Chameleon templating out of + the box in ZPT and text flavors. ZPT The `Zope Page Template `_ @@ -815,11 +815,10 @@ Glossary library, used by the :app:`Pyramid` translation machinery. Babel - A `collection of tools `_ for - internationalizing Python applications. :app:`Pyramid` does - not depend on Babel to operate, but if Babel is installed, - additional locale functionality becomes available to your - application. + A `collection of tools `_ for + internationalizing Python applications. :app:`Pyramid` does not depend on + Babel to operate, but if Babel is installed, additional locale + functionality becomes available to your application. Lingua A package by Wichert Akkerman which provides the ``pot-create`` -- cgit v1.2.3 From 94bad269d735dddeb9eade39341b6993c7127ce6 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Tue, 8 Mar 2016 00:22:05 -0800 Subject: rewrite renderer glossary entry to read more easily --- docs/glossary.rst | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index bbc86db41..9657d9219 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -558,12 +558,11 @@ Glossary A popular `Javascript library `_. renderer - A serializer that can be referred to via :term:`view - configuration` which converts a non-:term:`Response` return - values from a :term:`view` into a string (and ultimately a - response). Using a renderer can make writing views that require - templating or other serialization less tedious. See - :ref:`views_which_use_a_renderer` for more information. + A serializer which converts non-:term:`Response` return values from a + :term:`view` into a string, and ultimately into a response, usually + through :term:`view configuration`. Using a renderer can make writing + views that require templating or other serialization, like JSON, less + tedious. See :ref:`views_which_use_a_renderer` for more information. renderer factory A factory which creates a :term:`renderer`. See -- cgit v1.2.3 From b4147ba4b34b13eaf32f064e9827da733ff6ab7c Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Wed, 9 Mar 2016 01:01:58 -0600 Subject: add "view deriver" to the glossary --- docs/glossary.rst | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index bbc86db41..9e068a18c 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1092,3 +1092,8 @@ Glossary A technique used when serving a cacheable static asset in order to force a client to query the new version of the asset. See :ref:`cache_busting` for more information. + + view deriver + A view deriver is a composable component of the view pipeline which is + used to create a :term:`view callable`. A view deriver is a callable + implementing the :class:`pyramid.interfaces.IViewDeriver` interface. -- cgit v1.2.3 From 7fc181d89e9553b152618066490d1fb659d45e13 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Sun, 13 Mar 2016 16:24:53 -0500 Subject: add examples of view derivers to the glossary --- docs/glossary.rst | 2 ++ 1 file changed, 2 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9e068a18c..8928254f7 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1097,3 +1097,5 @@ Glossary A view deriver is a composable component of the view pipeline which is used to create a :term:`view callable`. A view deriver is a callable implementing the :class:`pyramid.interfaces.IViewDeriver` interface. + Examples of builtin derivers including view mapper, the permission + checker, and applying a renderer to a dictionary returned from the view. -- cgit v1.2.3 From 890ea8f7d57d680bd07e04bcab9a778d0f12f737 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Mon, 21 Mar 2016 04:34:43 -0700 Subject: polish view derivers docs, minor grammar --- docs/glossary.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 8928254f7..5e6aa145c 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1097,5 +1097,5 @@ Glossary A view deriver is a composable component of the view pipeline which is used to create a :term:`view callable`. A view deriver is a callable implementing the :class:`pyramid.interfaces.IViewDeriver` interface. - Examples of builtin derivers including view mapper, the permission + Examples of built-in derivers including view mapper, the permission checker, and applying a renderer to a dictionary returned from the view. -- cgit v1.2.3 From a7dd0531b427d8633fc222830f24b737048e9c8a Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Wed, 30 Mar 2016 05:53:35 -0700 Subject: update installation and glossary --- docs/glossary.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 9657d9219..ef90a0f41 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1091,3 +1091,7 @@ Glossary A technique used when serving a cacheable static asset in order to force a client to query the new version of the asset. See :ref:`cache_busting` for more information. + + pip + The `Python Packaging Authority `_ recommended tool + for installing Python packages. -- cgit v1.2.3 From ec1bbffae07cd8b573ba007b367b9eec2902a364 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sun, 10 Apr 2016 16:08:38 -0700 Subject: - update installation.rst to use pip, pyvenv, Python 3.4 - simplify installation.rst by removing not-Pyramid things (installing Python and requirements for installing packages) while providing official external references - update cross-reference in quick_tutorial requirements.rst - add glossary entry for pyvenv --- docs/glossary.rst | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index ef90a0f41..858f3de51 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1095,3 +1095,8 @@ Glossary pip The `Python Packaging Authority `_ recommended tool for installing Python packages. + + pyvenv + The Python Packaging Authority's recommended command for `creating + virtual environments on Python 3.4 and greater + `_. -- cgit v1.2.3 From 6b35eb6ca3b271e2943d37307c925c5733e082d9 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Sun, 10 Apr 2016 20:50:10 -0500 Subject: rewrite csrf checks to support a global setting to turn it on - only check csrf on POST - support "pyramid.require_default_csrf" setting - support "require_csrf=True" to fallback to the global setting to determine the token name --- docs/glossary.rst | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 039665926..ef9c66b99 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1098,3 +1098,11 @@ Glossary implementing the :class:`pyramid.interfaces.IViewDeriver` interface. Examples of built-in derivers including view mapper, the permission checker, and applying a renderer to a dictionary returned from the view. + + truthy string + A string represeting a value of ``True``. Acceptable values are + ``t``, ``true``, ``y``, ``yes``, ``on`` and ``1``. + + falsey string + A string represeting a value of ``False``. Acceptable values are + ``f``, ``false``, ``n``, ``no``, ``off`` and ``0``. -- cgit v1.2.3 From d603697517d56a1e2f2a5707ebba922db24f5c71 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Tue, 12 Apr 2016 02:47:57 -0700 Subject: - replace `pyvenv` with `python3 -m venv` --- docs/glossary.rst | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 1d8e0de1b..fd32ed796 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1100,10 +1100,16 @@ Glossary checker, and applying a renderer to a dictionary returned from the view. pip - The `Python Packaging Authority `_ recommended tool - for installing Python packages. + The `Python Packaging Authority's `_ recommended + tool for installing Python packages. pyvenv - The Python Packaging Authority's recommended command for `creating - virtual environments on Python 3.4 and greater - `_. + The Python Packaging Authority formerly recommended using this command + for `creating virtual environments on Python 3.4 and 3.5 + `_, + but it is deprecated in 3.6 in favor of ``python3 -m venv`` which is + backward compatible. + + venv + The `Python Packaging Authority's `_ recommended + tool for creating virtual environments. -- cgit v1.2.3 From d67566acebf890a603fad0e9069d5e131dfb5b31 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Tue, 12 Apr 2016 06:43:38 -0700 Subject: one does not simply "create a virtualenv". one should "create a virtual environment". - Fixes #2483 --- docs/glossary.rst | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index fd32ed796..4c17c0f0b 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -155,9 +155,9 @@ Glossary request before it returns a :term:`context` resource. virtualenv - A term referring both to an isolated Python environment, - or `the leading tool `_ that allows one to - create such environments. + The `virtualenv tool `_ that allows + one to create virtual environments. In Python 3.3 and greater, + :term:`venv` is the preferred tool. Note: whenever you encounter commands prefixed with ``$VENV`` (Unix) or ``%VENV`` (Windows), know that that is the environment variable whose @@ -1012,8 +1012,8 @@ Glossary console script A script written to the ``bin`` (on UNIX, or ``Scripts`` on Windows) - directory of a Python installation or :term:`virtualenv` as the result of - running ``setup.py install`` or ``setup.py develop``. + directory of a Python installation or :term:`virtual environment` as the + result of running ``pip install`` or ``pip install -e .``. introspector An object with the methods described by @@ -1110,6 +1110,14 @@ Glossary but it is deprecated in 3.6 in favor of ``python3 -m venv`` which is backward compatible. + virtual environment + An isolated Python environment that allows packages to be installed for + use by a particular application, rather than being installed system wide. + venv The `Python Packaging Authority's `_ recommended tool for creating virtual environments. + + Note: whenever you encounter commands prefixed with ``$VENV`` (Unix) + or ``%VENV`` (Windows), know that that is the environment variable whose + value is the root of the virtual environment in question. -- cgit v1.2.3 From 83d7d92ca5c44b9e63a537fb1d88834a945e25f3 Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Tue, 12 Apr 2016 13:53:05 -0700 Subject: - add mention of Windows and Python 3.3+ for virtual environments --- docs/glossary.rst | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 4c17c0f0b..655301a5c 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1107,8 +1107,9 @@ Glossary The Python Packaging Authority formerly recommended using this command for `creating virtual environments on Python 3.4 and 3.5 `_, - but it is deprecated in 3.6 in favor of ``python3 -m venv`` which is - backward compatible. + but it is deprecated in 3.6 in favor of ``python3 -m venv`` on UNIX or + ``python -m venv`` on Windows, which is backward compatible on Python + 3.3 and greater. virtual environment An isolated Python environment that allows packages to be installed for @@ -1116,7 +1117,7 @@ Glossary venv The `Python Packaging Authority's `_ recommended - tool for creating virtual environments. + tool for creating virtual environments on Python 3.3 and greater. Note: whenever you encounter commands prefixed with ``$VENV`` (Unix) or ``%VENV`` (Windows), know that that is the environment variable whose -- cgit v1.2.3 From b61a8ba298a7e474d4d209967791a0b13bc5d77d Mon Sep 17 00:00:00 2001 From: Steve Piercy Date: Sat, 16 Apr 2016 02:39:17 -0700 Subject: quick_tutorial cleanup - replace nose and coverage with pytest and pytest-cov - update glossary and terms - use doscon lexer for Windows commands - refer to Pyramid Installation and put an end to copy-pasta - fix directory tree --- docs/glossary.rst | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) (limited to 'docs/glossary.rst') diff --git a/docs/glossary.rst b/docs/glossary.rst index 486e94848..1d97bffe8 100644 --- a/docs/glossary.rst +++ b/docs/glossary.rst @@ -1108,14 +1108,15 @@ Glossary ``f``, ``false``, ``n``, ``no``, ``off`` and ``0``. pip - The `Python Packaging Authority's `_ recommended - tool for installing Python packages. + The :term:`Python Packaging Authority`'s recommended tool for installing + Python packages. pyvenv - The Python Packaging Authority formerly recommended using this command - for `creating virtual environments on Python 3.4 and 3.5 + The :term:`Python Packaging Authority` formerly recommended using the + ``pyvenv`` command for `creating virtual environments on Python 3.4 and + 3.5 `_, - but it is deprecated in 3.6 in favor of ``python3 -m venv`` on UNIX or + but it was deprecated in 3.6 in favor of ``python3 -m venv`` on UNIX or ``python -m venv`` on Windows, which is backward compatible on Python 3.3 and greater. @@ -1124,9 +1125,14 @@ Glossary use by a particular application, rather than being installed system wide. venv - The `Python Packaging Authority's `_ recommended - tool for creating virtual environments on Python 3.3 and greater. + The :term:`Python Packaging Authority`'s recommended tool for creating + virtual environments on Python 3.3 and greater. Note: whenever you encounter commands prefixed with ``$VENV`` (Unix) or ``%VENV`` (Windows), know that that is the environment variable whose value is the root of the virtual environment in question. + + Python Packaging Authority + The `Python Packaging Authority (PyPA) `_ + is a working group that maintains many of the relevant projects in Python + packaging. \ No newline at end of file -- cgit v1.2.3