Browse Source

Revert "[fix] is_werkzeug_reload_active is not realted to python -m"

This reverts commit 3392beb914591cac6e862dab66e4d4911b798800.
Markus Heiser 6 days ago
parent
commit
20ce88a274
1 changed files with 5 additions and 0 deletions
  1. 5 0
      searx/webapp.py

+ 5 - 0
searx/webapp.py

@@ -1383,6 +1383,11 @@ def is_werkzeug_reload_active() -> bool:
         if "--reload" in sys.argv or "--debug" in sys.argv:
             return True
 
+    elif frames[0].filename.endswith('searx/webapp.py'):
+        # server was launched by "python -m searx.webapp" / see run()
+        if searx.sxng_debug:
+            return True
+
     return False