From d85569e38ba88029864b7908dbee3f948b103712 Mon Sep 17 00:00:00 2001 From: Patricio Paez Date: Thu, 29 Nov 2012 22:10:38 -0600 Subject: Sync MyProject files with the starter scaffold - Line numbers are mentioned only in the Creating a Pyramid Project chapter; those that are affected were updated. --- docs/narr/project.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'docs/narr/project.rst') diff --git a/docs/narr/project.rst b/docs/narr/project.rst index b08948e43..fb62f4bd2 100644 --- a/docs/narr/project.rst +++ b/docs/narr/project.rst @@ -829,25 +829,25 @@ also informs Python that the directory which contains it is a *package*. #. Line 1 imports the :term:`Configurator` class from :mod:`pyramid.config` that we use later. -#. Lines 3-10 define a function named ``main`` that returns a :app:`Pyramid` +#. Lines 4-11 define a function named ``main`` that returns a :app:`Pyramid` WSGI application. This function is meant to be called by the :term:`PasteDeploy` framework as a result of running ``pserve``. Within this function, application configuration is performed. - Line 6 creates an instance of a :term:`Configurator`. + Line 7 creates an instance of a :term:`Configurator`. - Line 7 registers a static view, which will serve up the files from the + Line 8 registers a static view, which will serve up the files from the ``myproject:static`` :term:`asset specification` (the ``static`` directory of the ``myproject`` package). - Line 8 adds a :term:`route` to the configuration. This route is later + Line 9 adds a :term:`route` to the configuration. This route is later used by a view in the ``views`` module. - Line 9 calls ``config.scan()``, which picks up view registrations declared + Line 10 calls ``config.scan()``, which picks up view registrations declared elsewhere in the package (in this case, in the ``views.py`` module). - Line 10 returns a :term:`WSGI` application to the caller of the function + Line 11 returns a :term:`WSGI` application to the caller of the function (Pyramid's pserve). .. index:: @@ -865,7 +865,7 @@ and which returns a :term:`response`. :language: python :linenos: -Lines 3-5 define and register a :term:`view callable` named ``my_view``. The +Lines 4-6 define and register a :term:`view callable` named ``my_view``. The function named ``my_view`` is decorated with a ``view_config`` decorator (which is processed by the ``config.scan()`` line in our ``__init__.py``). The view_config decorator asserts that this view be found when a -- cgit v1.2.3 From 37da2cf374792b2ab12ae39be6994540c9dfe623 Mon Sep 17 00:00:00 2001 From: Marc Abramowitz Date: Mon, 4 Feb 2013 15:23:46 -0800 Subject: narr/project.rst: Correct IP address 129.168.1.50 -> 192.168.1.50 --- docs/narr/project.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/narr/project.rst') diff --git a/docs/narr/project.rst b/docs/narr/project.rst index fb62f4bd2..5a8ea0ecf 100644 --- a/docs/narr/project.rst +++ b/docs/narr/project.rst @@ -297,7 +297,7 @@ For example, your system might be configured to have an external IP address ``192.168.1.50``. If that's the case, if you use a browser running on the same system as Pyramid, it will be able to access the application via ``http://127.0.0.1:6543/`` as well as via -``http://129.168.1.50:6543/``. However, *other people* on other computers on +``http://192.168.1.50:6543/``. However, *other people* on other computers on the same network will also be able to visit your Pyramid application in their browser by visiting ``http://192.168.1.50:6543/``. -- cgit v1.2.3