From 58d190b5ff8d23bfd6635d879a0de54379e9fe63 Mon Sep 17 00:00:00 2001 From: Meer Sawood Date: Wed, 28 Jul 2021 16:50:44 +0530 Subject: [PATCH] fix: api linter configuration & monkey patch issue (#789) * fix: api linter configuration & monkey patch issue * Update gunicorn.py * Update setup.cfg * Update gunicorn.py --- bayesian/conf/gunicorn.py | 5 +++-- setup.cfg | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/bayesian/conf/gunicorn.py b/bayesian/conf/gunicorn.py index aef100f9..53f59b95 100644 --- a/bayesian/conf/gunicorn.py +++ b/bayesian/conf/gunicorn.py @@ -1,12 +1,13 @@ """Gunicorn config.""" # NOTE: Must be before we import or call anything that may be synchronous. from gevent import monkey + +monkey.patch_all() + import logging from bayesian.settings import GUNICORN_SETTINGS, log_all_settings from prometheus_flask_exporter.multiprocess import GunicornPrometheusMetrics -monkey.patch_all() - workers = GUNICORN_SETTINGS.workers worker_class = GUNICORN_SETTINGS.worker_class timeout = GUNICORN_SETTINGS.timeout diff --git a/setup.cfg b/setup.cfg index 999cf45a..80c217f2 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,2 +1,3 @@ [pycodestyle] -max-line-length = 100 \ No newline at end of file +max-line-length = 100 +ignore = E402,E121,E126,W504