fix iteritems, does not exist in python 3