Streamlit page deploys but says files don't exist

Here’s a link to one of the pages, the graphs are not loading: https://owen-fintech-projec-streamlit-dashboard01—introduction-6dq6au.streamlitapp.com/Comparing_Timeframes_Part_1

In the manage app panel it says no such file can be found but it was working before being deployed.

Any ideas how I can troubleshoot this? I have created a requirements .txt file which says:
pandas
holoviews
seaborn
hvplot
numpy
vaderSentiment
pathlib
bokeh>=2.4.0,<=2.4.1

Could I be going wrong with that somehow?

Is the app running and public.

Usually this might happen due to incorrect relative file paths when testing locally vs when deployed.
One way to fix is using os.path.join(os.getcwd, ‘dir1’,‘dir2’,‘path to file’) as file path

1 Like

Sorry, in my efforts to try figure out what was wrong I re-deployed the app (but it turned out I didn’t need to).

You were exactly right though, I had relative file paths that worked when testing locally. I eventually figured out the paths I should use when deployed that start with /app/

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.