Changeset 332 in lmdz_wrf for trunk/tools/create_OBSnetcdf.py


Ignore:
Timestamp:
Feb 27, 2015, 3:48:59 PM (10 years ago)
Author:
lfita
Message:

Adding a missing 'return'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/create_OBSnetcdf.py

    r259 r332  
    6969    attr = varobj.setncattr('long_name', vlname)
    7070    attr = varobj.setncattr('units', vunits)
     71
     72    return
    7173
    7274def remove_NONascii(string):
     
    9294    for ichar in range(Nchars):
    9395        foundchar = string.find(RTFchar[ichar])
    94         if foundchar != 0:
     96        if foundchar != -1:
    9597            newstring = newstring.replace(RTFchar[ichar], ASCchar[ichar])
    9698
     
    691693if opts.obsfile is None:
    692694    print errormsg
    693     print '  ' + main + ': No observtions file provided!!'
     695    print '  ' + main + ': No observations file provided!!'
    694696    quit(-1)
    695697
     
    828830# Time variable in CF format
    829831##
    830 print description['FMTtime'], 'CFtime'
    831832if description['FMTtime'] == 'CFtime':
    832833    timevals = datavalues[description['NAMEtime']]
     
    840841    # Time as a composition of different columns
    841842    tcomposite = description['NAMEtime'].find('@')
    842     if tcomposite != 0:
     843    if tcomposite != -1:
    843844        timevars = description['NAMEtime'].split('@')
    844845
Note: See TracChangeset for help on using the changeset viewer.