Skip to content

Commit

Permalink
fix: api linter configuration & monkey patch issue (#789)
Browse files Browse the repository at this point in the history
* fix: api linter configuration & monkey patch issue

* Update gunicorn.py

* Update setup.cfg

* Update gunicorn.py
  • Loading branch information
Meer Sawood authored Jul 28, 2021
1 parent 6d519c2 commit 58d190b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions bayesian/conf/gunicorn.py
Original file line number Diff line number Diff line change
@@ -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
Expand Down
3 changes: 2 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
[pycodestyle]
max-line-length = 100
max-line-length = 100
ignore = E402,E121,E126,W504

0 comments on commit 58d190b

Please sign in to comment.