🔧 fix(__main__.py): set "no_proxy" environment variable to "*" to avoid error with gunicorn in macos

This commit is contained in:
Gabriel Luiz Freitas Almeida 2023-10-18 19:57:28 -03:00
commit a497eebab1

View file

@ -61,6 +61,8 @@ def set_var_for_macos_issue():
import os
os.environ["OBJC_DISABLE_INITIALIZE_FORK_SAFETY"] = "YES"
# https://stackoverflow.com/questions/75747888/uwsgi-segmentation-fault-with-flask-python-app-behind-nginx-after-running-for-2 # noqa
os.environ["no_proxy"] = "*" # to avoid error with gunicorn
logger.debug("Set OBJC_DISABLE_INITIALIZE_FORK_SAFETY to YES to avoid error")