Skip to content

Commit

Permalink
change assertion to log errof if translation is None in varlist_util
Browse files Browse the repository at this point in the history
  • Loading branch information
wrongkindofdoctor committed Oct 25, 2024
1 parent 1d8a068 commit 37c1d88
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/varlist_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,8 @@ def setup_var(self,
v.dest_path = self.variable_dest_path(model_paths, case_name, v)
try:
trans_v = translate.translate(v, from_convention)
assert trans_v is not None, f'translation for varlistentry {v.name} failed'
if trans_v is None:
v.log.error(f'translation for varlistEntry {v.name} failed')
v.translation = trans_v
# copy preferred gfdl post-processing component during translation
if hasattr(trans_v, "component"):
Expand Down

0 comments on commit 37c1d88

Please sign in to comment.