File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -2300,18 +2300,22 @@ def check_timestep_in_file(fname):
2300
2300
def check_calendar_in_file (cname , calendar_found ):
2301
2301
"Checks what calendar is used for input file"
2302
2302
2303
- calendar_found = "missing"
2303
+ new_calendar = False
2304
2304
if check_attribute_in_file (cname , "time" , "calendar" , "noleap" ) is True :
2305
2305
calendar_found = "noleap"
2306
+ new_calendar = True
2306
2307
if check_attribute_in_file (cname , "time" , "calendar" , "360_day" ) is True :
2307
2308
calendar_found = "360"
2309
+ new_calendar = True
2308
2310
if check_attribute_in_file (cname , "time" , "calendar" , "gregorian" ) is True :
2309
2311
calendar_found = "leap"
2312
+ new_calendar = True
2310
2313
2311
2314
# CCAM special case
2312
2315
ccam_host = check_var_in_file (cname , ":version" )
2313
- if (ccam_host is True ) and (calendar_found == "missing" ):
2316
+ if (ccam_host is True ) and (new_calendar is False ):
2314
2317
calendar_found = "leap"
2318
+ new_calendar = True
2315
2319
2316
2320
return calendar_found
2317
2321
You can’t perform that action at this time.
0 commit comments