I asked ChatGPT to generate me a Streamlit app to show off as much Streamlit widgets and features as possible.
The app worked fine on my laptop but failed on my smartphone (browser) due to Matplotlib not found.
”ModuleNotFoundError” on Matplotlib.
Is there a way to make this work on my smartphone, having Matplotlib installed. Or is this too much to wish for….?
Well, Ray, Your phone can’t run the browser because it cannot find Matplotlib, but you have to use Pydroid for your phone, but to fix this, you can simply follow some steps that can help you:
1. Run the app on your laptop and use your phone to open it.
2. Put the app online (Google Cloud/AWS, Heroku).
3. Run Python on your phone.
I hope it will help you.
Mamta Bankoti
Well, I found the way to solve this.
In the Github folder, where the Streamlit app is stored, you have to add a ‘requirements.txt’ file that lists all the external modules/libraries that need to be imported.For example, something like this:
streamlit>=1.50.0
streamlit-option-menu==0.4.0
matplotlib
You can add versions if needed.
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.