diff options
Diffstat (limited to 'docs/narr/logging.rst')
| -rw-r--r-- | docs/narr/logging.rst | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/docs/narr/logging.rst b/docs/narr/logging.rst index a7ee0f1f8..ce83cd3ee 100644 --- a/docs/narr/logging.rst +++ b/docs/narr/logging.rst @@ -65,7 +65,7 @@ In this logging configuration: .. code-block:: text - 2007-08-17 15:04:08,704 INFO [packagename] Loading resource, id: 86 + 2007-08-17 15:04:08,704 INFO [packagename] Loading resource, id: 86 - a logger named ``myproject`` is configured that logs messages sent at a level above or equal to ``DEBUG`` to stderr in the same format as the root logger. @@ -235,7 +235,7 @@ Request Logging with Paste's TransLogger The :term:`WSGI` design is modular. Waitress logs error conditions, debugging output, etc., but not web traffic. For web traffic logging, Paste provides the -`TransLogger <http://pythonpaste.org/modules/translogger.html>`_ +`TransLogger <https://web.archive.org/web/20160707041338/http://pythonpaste.org:80/modules/translogger.html>`_ :term:`middleware`. TransLogger produces logs in the `Apache Combined Log Format <http://httpd.apache.org/docs/2.2/logs.html#combined>`_. But TransLogger does not write to files; the Python logging system must be @@ -276,7 +276,7 @@ function of your project's ``__init__`` file: .. code-block:: python - ... + # ... app = config.make_wsgi_app() from paste.translogger import TransLogger app = TransLogger(app, setup_console_handler=False) @@ -298,7 +298,7 @@ output to the console when we request a page: (content-type: text/plain) 00:50:53,695 INFO [wsgi] 192.168.1.111 - - [11/Aug/2011:20:09:33 -0700] "GET /hello HTTP/1.1" 404 - "-" - "Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.6) Gecko/20070725 + "Mozilla/5.0 (Macintosh; U; Intel macOS; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6" To direct TransLogger to an ``access.log`` FileHandler, we need the following |
