TUW-GEO / ascat

Read and visualize data from the Advanced Scatterometer (ASCAT) on-board the series of Metop satellites
https://ascat.readthedocs.io/
MIT License
23 stars 16 forks source link

Catch any exception on cell collection date regex #69

Closed claytharrison closed 2 weeks ago

claytharrison commented 1 month ago

Making a cell collection from a non-dated directory works currently only if the directory name format matches the "{date1}_{date2}" regex. That match should be allowed to fail and be handled. This change catches any exception in ascat.read_native.ragged_array_ts.CellFileCollection.date_range, rather than just the ValueError thrown when the regex matches the directory name but {date1} or {date2} is not actually a date, which is the current behavior.