def removeCommandWatcher(self, commandWatcher):
        print "\nREMOVING COMMAND WATCHER %d\n" % commandWatcher.command.id

        del self.commandWatchers[commandWatcher.commandId]
        del self.commands[commandWatcher.commandId]
        try:
            os.remove(commandWatcher.processObj.pidfile)
            if self.status is not rendernode.RN_PAUSED:
                # Only set status to IDLE if RN was not marked as pause (via mylawn or pulback)
                self.status = rendernode.RN_IDLE

        except OSError, e:
            from errno import ENOENT
            err, msg = e.args
            LOGGER.exception(msg)
            if err != ENOENT:
                raise
dataset/ETHPy150Open mikrosimage/OpenRenderManagement/src/octopus/worker/worker.py/Worker.removeCommandWatcher/original