I have a python project using Streamlit app. I have used poetry to build a package. After install using pip install. Trying to launch the app gives the following error.
WARNING streamlit.runtime.scriptrunner_utils.script_run_context: Thread ‘MainThread’: missing ScriptRunContext! This warning can be ignored when running in bare mode.
How do I package the Streamlit app in a python project and make it installable in local systems and launch the app.
Otherwise, there are multiple threads discussing different approaches people have taken, with various pros and cons depending on what you are trying to accomplish: Using PyInstaller (or similar) to create an executable
Once it is installed, you can run it with either myapp or python -m myapp.
It relies on undocumented features, but it is based on the same way streamlit itself runs applications. So, if it ever breaks, look at what is in streamlit.__main__.