summaryrefslogtreecommitdiff
path: root/docs/narr/extconfig.rst
diff options
context:
space:
mode:
authorMichael Merickel <michael@merickel.org>2015-02-17 18:58:53 -0600
committerMichael Merickel <michael@merickel.org>2015-02-17 18:58:53 -0600
commit568a025d3156ee1e7bdf92e14c9eba7390c1dd26 (patch)
treeddbe02d150246bec02295f43bc36eeae3f518bb4 /docs/narr/extconfig.rst
parentd4333972ad328f06262ba55ef2a3d24963da95b0 (diff)
downloadpyramid-568a025d3156ee1e7bdf92e14c9eba7390c1dd26.tar.gz
pyramid-568a025d3156ee1e7bdf92e14c9eba7390c1dd26.tar.bz2
pyramid-568a025d3156ee1e7bdf92e14c9eba7390c1dd26.zip
expose public config phases in pyramid.config
Diffstat (limited to 'docs/narr/extconfig.rst')
-rw-r--r--docs/narr/extconfig.rst17
1 files changed, 10 insertions, 7 deletions
diff --git a/docs/narr/extconfig.rst b/docs/narr/extconfig.rst
index c4d3e0250..c805f1572 100644
--- a/docs/narr/extconfig.rst
+++ b/docs/narr/extconfig.rst
@@ -243,12 +243,17 @@ This means that if an action must be reliably executed before or after another
action, the ``order`` must be defined explicitly to make this work. For
example, views are dependent on routes being defined. Thus the action created
by :meth:`pyramid.config.Configurator.add_route` has an ``order`` of
-:const:`pyramid.interfaces.PHASE2_CONFIG`.
+:const:`pyramid.config.PHASE2_CONFIG`.
Pre-defined Phases
~~~~~~~~~~~~~~~~~~
-:const:`pyramid.interfaces.PHASE1_CONFIG`
+:const:`pyramid.config.PHASE0_CONFIG`
+
+- This phase is reserved for developers who want to execute actions prior
+ to Pyramid's core directives.
+
+:const:`pyramid.config.PHASE1_CONFIG`
- :meth:`pyramid.config.Configurator.add_renderer`
- :meth:`pyramid.config.Configurator.add_route_predicate`
@@ -258,12 +263,12 @@ Pre-defined Phases
- :meth:`pyramid.config.Configurator.set_default_permission`
- :meth:`pyramid.config.Configurator.set_view_mapper`
-:const:`pyramid.interfaces.PHASE2_CONFIG`
+:const:`pyramid.config.PHASE2_CONFIG`
- :meth:`pyramid.config.Configurator.add_route`
- :meth:`pyramid.config.Configurator.set_authentication_policy`
-``0``
+:const:`pyramid.config.PHASE3_CONFIG`
- The default for all builtin or custom directives unless otherwise specified.
@@ -285,9 +290,7 @@ but we want it to conflict with any other call to our addon:
.. code-block:: python
:linenos:
- from pyramid.interfaces import PHASE1_CONFIG
-
- PHASE0_CONFIG = PHASE1_CONFIG - 10
+ from pyramid.config import PHASE0_CONFIG
def includeme(config):
config.add_directive(add_auto_route, 'add_auto_route')