def get_oldest(class_name):
 for (cls, wdict) in six.iteritems(live_refs):
  if (cls.__name__ == class_name):
   if (not wdict):
    break
   return min(six.iteritems(wdict), key=itemgetter(1))[0]

def get_oldest ( class_name ) : for ( cls , wdict ) in six . iteritems ( live_refs ) : if ( cls . __name__ == class_name ) : if ( not wdict ) : break return min ( six . iteritems ( wdict ) , key = itemgetter ( 1 ) ) [ 0 ]
get the oldest object for a specific class name .