Skip to content

Commit

Permalink
FATAL ERROR
Browse files Browse the repository at this point in the history
Co-authored-by: Walter Kolczynski - NOAA <[email protected]>
  • Loading branch information
zmoon and WalterKolczynski-NOAA authored Dec 3, 2024
1 parent bc9e8f9 commit 62d1702
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ush/python/pygfs/task/aero_emissions.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def open_qfed(files: List[str], out_var_dict: Dict[str, str] = None) -> xr.Datas
da.name = out_var_dict[input_var]
dset_dict[da.name] = da
except Exception as e:
logger.exception(f"Unable to read dataset: {f}")
logger.exception(f"FATAL ERROR: Unable to read dataset: {f}")
raise Exception("FATAL ERROR: Unable to read dataset, ABORT!") from e

dset = xr.Dataset(dset_dict)
Expand Down Expand Up @@ -217,7 +217,7 @@ def open_climatology(files: List[str]) -> xr.Dataset:
with xr.open_dataset(f, engine="netcdf4") as da:
das.append(da)
except Exception as e:
logger.exception(f"Encountered an error reading climatology file: {f}")
logger.exception(f"FATAL ERROR: Encountered an error reading climatology file: {f}")
raise Exception("FATAL ERROR: Unable to read file, ABORT!") from e

return xr.concat(das, dim="time")
Expand Down Expand Up @@ -253,7 +253,7 @@ def write_ncf(dset: xr.Dataset, outfile: str) -> None:
try:
dset.load().to_netcdf(outfile, encoding=encoding)
except Exception as e:
logger.exception("Encountered an error writing dataset")
logger.exception("FATAL ERROR: Encountered an error writing dataset")
raise Exception("FATAL ERROR: Unable to write dataset, ABORT!") from e

@staticmethod
Expand Down

0 comments on commit 62d1702

Please sign in to comment.