usgs / groundmotion-processing

Parsing and processing ground motion data
Other
54 stars 42 forks source link

Deal with error from newly supported IRISPH5 client during download #918

Closed gferragu closed 2 years ago

gferragu commented 2 years ago

Our handling of FDSN clients in fdsn_fetcher.py does not take into account the newly added support for IRIS PH5 in ObsPy 1.3.0. To prevent download errors or accidentally downloading a large active-source or array dataset via PH5, ObsPy removes IRISPH5 from their providers by default when MassDownloader() is called without an explicit provider parameter. With ObsPy 1.3.0, the URL_MAPPINGS dict still contains IRISPH5, however, and we use this dict to initialize our list of Client() objects in fdsn_fetcher.py. This PR checks for that dict entry and removes it before proceeding, resolving the issue of failed downloads.