'The thread which completes a package marks it as done with
this method.'

def return_built(self, package, successful=True):

    with self.condition:
        if successful:
            self.built.append(package)
        else:
            self.failed.append(package)
        if (package in self._started.keys()):
            self._started.pop(package)
        else:
            pass
        if self.is_completed():
            self._done = True
        self.condition.notifyAll()
