Running streamlit app installed as a PyPi package

I’ve created a Steamlit based data viz app and have deployed it on TestPyPi - however, I am now not sure how the end user/ installer of the package will be able to launch it?

I created a run_me.py file with the below in:

import sys
from streamlit import cli as stcli

sys.argv = ["streamlit", "run", "basic_app_4.py"]
sys.exit(stcli.main())

However, I really need to pass in the full path (location) of where the basic_app_4.py file will be located (as placed during the install).

I found a way to get the path - however I can’t find a way to include that path before the .py file listed above.

I am new to this - so not sure it’s even possible or if I am explaining myself correctly.

Ultimately - I want installers of the package to be able to launch the app - just don’t know best how to achieve it! TIA

1 Like

Hi! did you figure out a solution? I am also trying to do this.