def iteritems(self): with _IterationGuard(self): for wr, value in self.data.iteritems(): key = wr() if key is not None: yield key, value