From d20a26a347915836fd18c69ddffd234eee7dd2e4 Mon Sep 17 00:00:00 2001 From: Cuong Tran Date: Tue, 20 Nov 2018 00:08:28 +0000 Subject: [PATCH] updated styling --- gunicorn/config.py | 19 ++++++++++--------- gunicorn/glogging.py | 2 +- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/gunicorn/config.py b/gunicorn/config.py index 15272009..eac77a75 100644 --- a/gunicorn/config.py +++ b/gunicorn/config.py @@ -627,11 +627,11 @@ class WorkerClass(Setting): A string referring to one of the following bundled classes: * ``sync`` - * ``eventlet`` - Requires eventlet >= 0.9.7 (or install it via + * ``eventlet`` - Requires eventlet >= 0.9.7 (or install it via ``pip install gunicorn[eventlet]``) - * ``gevent`` - Requires gevent >= 0.13 (or install it via + * ``gevent`` - Requires gevent >= 0.13 (or install it via ``pip install gunicorn[gevent]``) - * ``tornado`` - Requires tornado >= 0.2 (or install it via + * ``tornado`` - Requires tornado >= 0.2 (or install it via ``pip install gunicorn[tornado]``) * ``gthread`` - Python 2 requires the futures package to be installed (or install it via ``pip install gunicorn[gthread]``) @@ -668,7 +668,7 @@ class WorkerThreads(Setting): If it is not defined, the default is ``1``. This setting only affects the Gthread worker type. - + .. note:: If you try to use the ``sync`` worker type and set the ``threads`` setting to more than 1, the ``gthread`` worker type will be used @@ -1368,8 +1368,9 @@ class LogConfigDict(Setting): desc = """\ The log config dictionary to use, using the standard Python logging module's dictionary configuration format. This option - takes precedence over the :ref:`logconfig` and :ref:`logConfigJson` options, which uses the - older file configuration format and JSON respectively. + takes precedence over the :ref:`logconfig` and :ref:`logConfigJson` options, + which uses the older file configuration format and JSON + respectively. Format: https://docs.python.org/3/library/logging.config.html#logging.config.dictConfig @@ -1385,11 +1386,11 @@ class LogConfigJson(Setting): validator = validate_string default = None desc = """\ - The log config JSON reads config from a JSON file + The log config to read config from a JSON file - Format: https://docs.python.org/3/library/logging.config.html#logging.config.dictConfig + Format: https://docs.python.org/3/library/logging.config.html#logging.config.jsonConfig - .. versionadded:: 19.9 + .. versionadded:: 20.0 """ diff --git a/gunicorn/glogging.py b/gunicorn/glogging.py index 966abe3d..e32fdf09 100644 --- a/gunicorn/glogging.py +++ b/gunicorn/glogging.py @@ -246,7 +246,7 @@ class Logger(object): config_json = json.load(open(cfg.logconfig_json)) config.update(config_json) dictConfig(config) - except( + except ( json.JSONDecodeError, AttributeError, ImportError,