I’ve been running Streamlit locally, and it worked perfectly for weeks. However, today, my app suddenly stopped updating when I make code changes, unless I manually re-run the app from the console.
For example, I start the app with: streamlit run data_upload/run.py
It initially runs the newest version of the code, but any subsequent changes aren’t picked up—refreshing the page, clicking “Rerun”, clearing the browser cache, or other steps don’t help.
I’ve tried installing Watchdog and adding the following to my configuration:
[server]
fileWatcherType = "watchdog"
Despite this, the code still seems cached somehow. I can see in the console output that the old code is being executed (e.g., error messages from removed code still appear). From the logs, watchdog seems to be working fine, it recognises that file has been changed.
This started happening with 1.39.1 to I updated to the latest version (1.41.1), but still the same issue. The weirdest think is that this started happening without me installing or updating anything.
Here are version of the app and my sustem:
OS: Mac OS 15.1 (M2)
Python version: 3.12.2
Streamlit version: 1.41.1
How can I debug this?