Run on local, but error in deployment

FileNotFoundError: This app has encountered an error. The original error message is redacted to prevent data leaks. Full error details have been recorded in the logs (if you’re on Streamlit Cloud, click on ‘Manage app’ in the lower right of your app).

Traceback:

File "/home/adminuser/venv/lib/python3.12/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 534, in _run_script
    exec(code, module.__dict__)File "/mount/src/air-quality-dicoding-advance-analysis/Dashboard/pages/1_📌_main_pages.py", line 31, in <module>
    df_main = load_data()

github repo:

It looks from your repository that you’ve found the error: Community Cloud uses the root of your repository as its working directory, so when you deploy your app it does:

streamlit run dashboard/hello.py

That means paths are handled differently than if you called streamlit run from the dashboard directory.