Commit c48c7b11 authored by Javier Vegas-Regidor's avatar Javier Vegas-Regidor
Browse files

Fix cmorized check at startup

parent bbbb838b
......@@ -422,7 +422,8 @@ class DataConvention(object):
var_path = self.get_file_path(
startdate, member, domain, var, cmor_var, chunk, frequency=freq
)
if os.path.isfile(var_path):
for path in (var_path, var_path.replace('/original_files/', '/')):
if os.path.isfile(path):
current_count += 1
if current_count >= self.config.cmor.min_cmorized_vars:
break
......@@ -984,6 +985,8 @@ class Cmor3Convention(DataConvention):
"""
startdate_path = self.get_startdate_path(startdate)
if not os.path.isdir(startdate_path):
startdate_path = startdate_path.replace('/original_files/', '/')
if not os.path.isdir(startdate_path):
return False
count = 0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment