def timeconvert(timestr):
 timestamp = None
 timetuple = email.utils.parsedate_tz(timestr)
 if (timetuple is not None):
  timestamp = email.utils.mktime_tz(timetuple)
 return timestamp

def timeconvert ( timestr ) : timestamp = None timetuple = email . utils . parsedate_tz ( timestr ) if ( timetuple is not None ) : timestamp = email . utils . mktime_tz ( timetuple ) return timestamp
convert rfc 2822 defined time string into system timestamp .