summaryrefslogtreecommitdiff
path: root/searx/webapp.py
diff options
context:
space:
mode:
authorMarkus Heiser <markus.heiser@darmarit.de>2025-04-24 17:24:51 +0200
committerMarkus Heiser <markus.heiser@darmarit.de>2025-04-24 17:24:51 +0200
commit33729439c5f1b555c6070e24c1f175605cb0ec77 (patch)
treecb2855e34b8f3e21350e888484f6e44d062f3781 /searx/webapp.py
parent20ce88a2749fc0c12aa219ee0d9a42395a9b17c3 (diff)
[fix] is_werkzeug_reload_active is not realted to python -m
Werkzeug's reloader is not active when was server is launched by uWSGI. Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'searx/webapp.py')
-rwxr-xr-xsearx/webapp.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/searx/webapp.py b/searx/webapp.py
index 4ecaab7d2..3b4cf1604 100755
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -1373,6 +1373,10 @@ def is_werkzeug_reload_active() -> bool:
https://werkzeug.palletsprojects.com/en/stable/serving/#werkzeug.serving.run_simple
"""
+ if "uwsgi" in sys.argv:
+ # server was launched by uWSGI
+ return False
+
# https://github.com/searxng/searxng/pull/1656#issuecomment-1214198941
# https://github.com/searxng/searxng/pull/1616#issuecomment-1206137468