Since streamlit 1.18.0, original endpoint names were migrated to new ones under _stcore (e.g. _stcore/stream) (see #5534) and this breaks some systems, specifically those behind reverse proxies or arrangements with forwarding rules that you cannot change in a heartbeat (see #6095).
This repo contains a string replacement patch that forces streamlit to use the old endpoints of /stream (and friends like /health).
Last tested with streamlit 1.19.0.
pip install streamlit-endpoint-patch
2 methods.
- Install package once
pip install streamlit-endpoint-patch
- Execute the following in your virtualenv/pyenv/whatever
streamlit-endpoint-patch
- Copy
streamlit_endpoint_patch/endpoint_coersion.pyto where you see fit - Activate virtualenv if you have one
- Execute the following in your virtualenv/pyenv/whatever
python streamlit_endpoint_patch/endpoint_coersion.py # or wherever you put the .pypip install streamlit=<your version>