Changeset 2484 in lmdz_wrf for trunk


Ignore:
Timestamp:
Apr 29, 2019, 8:52:58 PM (6 years ago)
Author:
lfita
Message:

Adding `calendar_type' as accepted calendar attribute

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/generic_tools.py

    r2482 r2484  
    27442744    y360 = False
    27452745    daycal360 = ['earth_360d', '360d', '360days', '360_day']
    2746     if searchInlist(attvar, 'calendar'):
    2747         calendar = times.getncattr('calendar')
     2746    if searchInlist(attvar, 'calendar') or searchInlist(attvar, 'calendar_type'):
     2747        if searchInlist(attvar, 'calendar'): calendar = times.getncattr('calendar')
     2748        else: calendar = times.getncattr('calendar_type')
    27482749        if searchInlist(daycal360,calendar):
    27492750            print warnmsg
Note: See TracChangeset for help on using the changeset viewer.