def op(self):
        _log.debug("%s.next()" % self.__str__())
        if self.zero_set:
            _log.debug("%s.next() REMOVE INFINITE" % self.__str__())
            raise StopIteration
        if all(self.final.values()):
            _log.debug("%s.next() REMOVE THESE %s" % (self.__str__(), str(self.remove)))
            # All remove values obtained just filter first
            # The first's exception are exposed
            while True:
                n = self.first.next()
                _log.debug("%s.next() = %s" % (self.__str__(), str(n)))
                if n not in self.remove:
                    self.remove.add(n)  # Enforce set behaviour 
                    _log.debug("%s.next() ACTUAL = %s" % (self.__str__(), str(n)))
                    return n
        paused = False
        for v in self.iters:
            try:
                while True:
                    self.remove.add(v.next())
            except PauseIteration:
                paused = True
            except StopIteration:
                self.final[id(v)] = True
        if paused:
            raise PauseIteration
        else:
            # Need to call ourself since while collecting removes can only raise PauseIteration
            return self.op()
dataset/ETHPy150Open EricssonResearch/calvin-base/calvin/utilities/dynops.py/Difference.op/original