'When running Flask on local, how can I specify the reloader (stat instead of watchdog)
I am running a Flask application on local (Windows) using the flask run on command prompt. By default, the stat reloader is used, which works great for me. I have recently started using celery for a task queue. To get the celery worker to auto-reload I am using watchmedo, which required me to install watchdog in the virtual environment. Now Flask has automatically started using watchdog instead of stat, which causes unnecessary reloads i.e. reloading even when non-application python files (located outside the application root folder but in the environment folder) get updated.
I have 2 questions around this:
- When using the
flask runmethod to run the flask application, can I specify the reloader type to use (stat instead of watchdog). - If that's not possible, can I configure watchdog (that's automatically getting used) to ignore py/pyc files outside the application root folder?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|

