def touchFile(fname, atime=None):
 if (atime is not None):
  try:
   with io.open(fname, u'a'):
    os.utime(fname, (atime, atime))
    return True
  except OSError as e:
   if (e.errno == errno.ENOSYS):
    sickrage.srCore.srLogger.debug(u'File air date stamping not available on your OS. Please disable setting')
   elif (e.errno == errno.EACCES):
    sickrage.srCore.srLogger.error((u'File air date stamping failed(Permission denied). Check permissions for file: %s' % fname))
   else:
    sickrage.srCore.srLogger.error((u'File air date stamping failed. The error is: %r' % e))
 return False

def touchFile ( fname , atime = None ) : if ( atime is not None ) : try : with io . open ( fname , u'a' ) : os . utime ( fname , ( atime , atime ) ) return True except OSError as e : if ( e . errno == errno . ENOSYS ) : sickrage . srCore . srLogger . debug ( u'File air date stamping not available on your OS. Please disable setting' ) elif ( e . errno == errno . EACCES ) : sickrage . srCore . srLogger . error ( ( u'File air date stamping failed(Permission denied). Check permissions for file: %s' % fname ) ) else : sickrage . srCore . srLogger . error ( ( u'File air date stamping failed. The error is: %r' % e ) ) return False
touch a file .