ModuleNotFoundError on Streamlit Share

Hello,

I’m trying to deploy my app on streamlit share. Looking really sleek so far, but I’m running into an issue that I hope has a quick fix. When deploying I get “ModuleNotFoundError: no module named matplotlib”. I created my requirements.txt w/ pipreqs, which you can see here: https://github.com/nsteingps/Firescape. I did see the known bug w/ matplotlib threading and have not wrapped my core, but I don’t think that would be responsible for this error(?). Any ideas?

Thanks!

Hi @nsteingps, welcome to the Streamlit community!

If I had to guess, I suspect its because GDAL isn’t available on the image. Looks like you’re close with the AptFile, but I believe we require that to be named packages.txt.

Best,
Randy

Hi Randy,

Thanks for the quick reply. That got me past the matplotlib issue. If you would indulge me on a related issue, I removed gdal from requirements.txt and renamed AptFile to packages.txt, but am still getting a modulenotfound error for gdal. Have I structured packages.txt correctly? The impossibility (to me) of installing gdal is actually what drove me away from Heroku to try streamlit share, ha.

Thanks again for your help.