From a4b173f8f4790a9808b3f09c5e55c4908f7f20eb Mon Sep 17 00:00:00 2001 From: Joan Perez i Cauhe Date: Fri, 27 Mar 2020 12:15:57 +0100 Subject: [PATCH] Print more info on decompress error. --- noaweather/weathersource.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/noaweather/weathersource.py b/noaweather/weathersource.py index 1758525..66f7664 100644 --- a/noaweather/weathersource.py +++ b/noaweather/weathersource.py @@ -407,8 +407,8 @@ def download(cls, url, file_path, binary=False, **kwargs): os.rename(file_path, tmp_file) cls.decompress_grib(tmp_file, file_path, wgrib2, spinfo) util.remove(tmp_file) - except OSError: - raise GribDownloaderError('Unable to decompress: %s' % file_path) + except OSError as err: + raise GribDownloaderError('Unable to decompress: %s \n\t%s' % (file_path, str(err))) return file_path