The app works fine locally. When I’m trying to deploy the app it works at first, but when going to the ‘archive’ page I get this message on the page itself (not in the log):
Network issue: Cannot load Streamlit frontend code. This can happen when you update Streamlit while a Streamlit app is running. To fix this, simply reload this app by pressing F5, Ctrl+R, or Cmd+R. If the error persists, try force-clearing your browser’s cache as described here
There are no errors in the log. The other pages of the data app work fine, so I think it might have something to do with the things I load/packages I use in the ‘archive’ page? The page should have sliders, load a netcdf file with xarray, and plot a map using matplotlib and cartopy.
Things I’ve tried:
Clearing my browser’s cache as mentioned in the error message.
Using another browser
Using conda instead of pip for packages installation
Deploy the data app without loading the netcdf file with xarray: the problem persists.
Plotting with matplotlib and cartopy: the app crashes without giving and error.
Just using matplotlib without cartopy: the data app works fine.
So there might be an issue with using Cartopy to plot, but as there is no error messages I don’t really know why.
O sorry for not responding! It did really help and thanks so much for your time. I thought it worked after that and didn’t have time to look at it again until a few weeks ago. The project was made private again on Github as I didn’t want the data to be fully public yet.
I did have a look at the possibility of it being an issue with the data like you suggested, but the error persists if I try to do the same plot without loading the data. I thought it would be a good idea to open a new thread because the problem doesn’t link to the original question anymore.
Did you use the Docker environment from my December fork for local testing and debugging? Or at least a virtualenv? Otherwise it will be an endless trial and error if you don’t have a clean local environment.
I forked your repo and tried to figure out the problem. At the beginning i got segmentation faults and tons of HDF5 error messages. That’s probably why the streamlit app on streamlit cloud crashed without any noticeable error message.
After some research i suspected that the binary python wheels of the different packages have some incompatibilities. So I added the dev headers and forced the suspicious packages to be built by pip from the sources. Et voila, the errors were gone.
O wow thank you so much! It works like a charm! I don’t think I would have ever figured this out myself, I’ll have to look at those Docker environments (have never used that before).
Wow, this is amazing debug skills, and generosity with your time!
Thank you @Franky1!! I had been trying to help @Isolde IRL, but this really stumped us. So, just dropping my appreciate here, especially as it also gives us some insight on how to approach future issues as we deploy our apps.
Hi @Franky1 , I would like to try out a Docker to debug my own issues with the app. How do I set it up in a way to rebuild the Streamlit environment?
Thanks a lot!
The thing is that it gives me an “SError: Error no file named tf_model.h5 or pytorch_model.bin found in directory model/” even though everything should be in place. I thought it might be a similar issue with data formats, which is why I posted it here.
Thanks for stopping by! We use cookies to help us understand how you interact with our website.
By clicking “Accept all”, you consent to our use of cookies. For more information, please see our privacy policy.
Cookie settings
Strictly necessary cookies
These cookies are necessary for the website to function and cannot be switched off. They are usually only set in response to actions made by you which amount to a request for services, such as setting your privacy preferences, logging in or filling in forms.
Performance cookies
These cookies allow us to count visits and traffic sources so we can measure and improve the performance of our site. They help us understand how visitors move around the site and which pages are most frequently visited.
Functional cookies
These cookies are used to record your choices and settings, maintain your preferences over time and recognize you when you return to our website. These cookies help us to personalize our content for you and remember your preferences.
Targeting cookies
These cookies may be deployed to our site by our advertising partners to build a profile of your interest and provide you with content that is relevant to you, including showing you relevant ads on other websites.