Check if any managed processes are still running.

@return bool
167914
public function hasAlive()
    {
        foreach ($this->processes as $pid => $process) {
            if ($process->isAlive()) {
                return true;
            }
        }

        return false;
    }
657688
public function hasSoftDeleting()
    {
        if (!$this->hasDeleting()) {
            return false;
        }

        $managedModelClass = $this->getManagedModel();

        return in_array(
            SoftDeletes::class, class_uses_recursive(get_class(new $managedModelClass()))
        ) && $this->hasDeleting();
    }
631318
public function valid() {
        if (!isset($this->za)) {
            return false;
        }

        // Skip over unwanted system files (get_info will return false).
        while (!$this->get_info($this->pos) && $this->pos < $this->za->numFiles) {
            $this->next();
        }

        // No files left - we're at the end.
        if ($this->pos >= $this->za->numFiles) {
            return false;
        }

        return true;
    }
1328568
public function isExempt()
    {
        $ignoreEnvs = $this->app['config']->get('maintenancemode.exempt-environments', []);

        if(is_array($ignoreEnvs) && in_array($this->app->environment(), $ignoreEnvs))
        {
            return true;
        }

        // We did not have a match
        return false;
    }
684260
protected function isExpired()
    {
        if (! $this->filesystem->exists($this->cached)) {
            return true;
        }

        $lastModified = $this->filesystem->lastModified($this->file->getPath());

        return $lastModified >= $this->filesystem->lastModified($this->cached);
    }
1111101
def is_running(self):
        
        pid = self.get_pid()
        if pid is None:
            return False
        # The PID file may still exist even if the daemon isn't running,
        # for example if it has crashed.
        try:
            os.kill(pid, 0)
        except OSError as e:
            if e.errno == errno.ESRCH:
                # In this case the PID file shouldn't have existed in
                # the first place, so we remove it
                self.pid_file.release()
                return False
            # We may also get an exception if we're not allowed to use
            # kill on the process, but that means that the process does
            # exist, which is all we care about here.
        return True
91881
def is_running?
      return false if state != "exporting"
      begin
        Process.getpgid(exporter_pid)
        raise Exceptions::ExportIgnored.new("Ignored")
      rescue Errno::ESRCH
        return false
      end
    end
1210761
protected function is_updated() {

		if ( $this->is_active() && isset( $this->plugin[ $this->slug ]['last-update'] ) ) {

			$interval    = Plugin::WP_Plugin_Info()->getOption( 'interval' );
			$last_update = $this->plugin[ $this->slug ]['last-update'];

			if ( ( time() - $last_update ) < $interval ) {
				return true;
			}
		}

		return false;
	}
1297084
public function isAlive()
    {
        if ($this->getStatus() == Aoe_Scheduler_Model_Schedule::STATUS_RUNNING) {
            if (time() - strtotime($this->getLastSeen()) < 2 * 60) { // TODO: make this configurable
                return true;
            } elseif ($this->getHost() == gethostname()) {
                if ($this->checkPid()) {
                    $this
                        ->setLastSeen(strftime('%Y-%m-%d %H:%M:%S', time()))
                        ->save();
                    return true;
                } else {
                    $this->markAsDisappeared(sprintf('Process "%s" on host "%s" cannot be found anymore', $this->getPid(), $this->getHost()));
                    return false; // dead
                }
            } else {
                // we don't know because the task is running on a different server
                return null;
            }
        }
        return false;
    }
909582
public function is_finished() {

        if ($this->finished === null) {
            $endtime = $this->get_end();
            if ($endtime === 0 || $this->now < $endtime) {
                // It is not yet finished or no idea when it finishes.
                $this->finished = false;
            } else {
                $this->finished = true;
            }
        }

        return $this->finished;
    }
1033785
def is_running(self):
        
        self.__update_status()
        return self.status == Status.UP or self.status == Status.DECOMMISSIONED
1167166
protected function runningProcesses()
    {
        $count = 0;
        foreach ($this->processes as $process) {
            if ($process->isRunning()) {
                $count++;
            }
        }

        return $count;
    }
657689
public function process()
    {
        $this->report->deleteExpired();
        $this->history->deleteExpired();

        // Delete files in temporary directory
        foreach (gplcart_file_scan_recursive(GC_DIR_PRIVATE_TEMP) as $file) {
            if (strpos(basename($file), '.') !== 0) { // Ignore hidden files
                gplcart_file_delete_recursive($file);
            }
        }

        $result = $this->report->checkFilesystem();

        if ($result !== true) {
            foreach ((array) $result as $message) {
                $this->logger->log('system_status', array('message' => $message), 'warning');
            }
        }

        return true;
    }
867789
def is_running(self):
        
        pp = self.pid
        if pp:
            try:
                proc = psutil.Process(pp)

                # Possible status:
                # "STATUS_RUNNING", "STATUS_IDLE",
                # "STATUS_SLEEPING", "STATUS_DISK_SLEEP",
                # "STATUS_STOPPED", "STATUS_TRACING_STOP",
                # "STATUS_ZOMBIE", "STATUS_DEAD",
                # "STATUS_WAKING", "STATUS_LOCKED",

                if proc.status in (psutil.STATUS_STOPPED,
                                   psutil.STATUS_DEAD,
                                   psutil.STATUS_ZOMBIE):
                    # The PID is still in the process table so call stop to
                    # remove the PID.
                    self.stop()
                    return False
                else:
                    # OK, it's running.
                    return True

            except psutil.NoSuchProcess:
                pass
        return False
1326216
public function get_current_run() {
        global $CFG;

        // Get number of parallel runs if not passed.
        if (empty($this->currentrun) && ($this->currentrun !== false) && !empty($CFG->behatrunprocess)) {
            $this->currentrun = $CFG->behatrunprocess;
        }

        return $this->currentrun;
    }
803332
public function isDone()
    {
        return (is_null($this->lastProtoResponse) || is_null($this->lastProtoResponse->getDone()))
            ? false
            : $this->lastProtoResponse->getDone();
    }
505147
def is_running(self):
        

        if self._process:
            if self._process.returncode is None:
                return True
            else:
                self._process = None
        return False