Closed AthKouloumvakos closed 2 years ago
Closed by: 3bb2bb76e7bd6b5ac287115bf2e16a5a639155c8
I add a try+except to handle the errors.
This may need some further work in the future.
For example when a problematic file is recongnized we can remove this directly or notify the user to do so.
There are two situations when curently the
download_fits
results to error and the use of the app is interrupted.The first is when a .fits file is corrupted and it cannot be imported by sunpy.Map. Sometimes this happens when the net connection is bad and the fido fetches the data incomplete from VSO.
This results to the following error for example: OSError: Failed to read /sunpy/data/20120712_170800_d4c2b.fts If the the user removes the file manually and rerun the download process, then the file is downloaded again and loads correct. However, the resulted error has the effect to reset the application status, so it needs a fix.
The second error appear when the ssl certificate verification sometimes errors as follows: Cannot connect to host seal.nascom.nasa.gov:443 ssl:True [SSLCertVerificationError: (1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:1129)')]
In this case the data are not downloaded or loaded at all. So the application returs an error in any case. Untill the remote server issue is resolved the app cannot be used and this is a problem