MCPcopy Create free account
hub / github.com/aaPanel/BaoTa / real_run_stop

Method real_run_stop

mod/project/java/groupMod.py:610–629  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

608 return
609
610 def real_run_stop(self):
611 pid_file = "{}/{}.pid".format(Group.GROUP_TMP_DIR, self.group_id)
612 pid = os.getpid()
613 public.writeFile(pid_file, str(pid))
614 if not self.can_running():
615 self.running_data["msg"] = "项目组配置文件错误,无法停止该项目组"
616 self.running_data["status"] = False
617 self.save_running_data()
618 return
619
620 # 构建运行启动的信息,并返回运行顺序
621 self.running_data["msg"] = "项目组停止操作运行中"
622 run_sort = self.build_run_sort(reverse=True)
623 self.save_running_data()
624 for idx, g in enumerate(run_sort):
625 self._run_stop_one_step(g, sort_idx=idx)
626
627 self.running_data["msg"] = "停止操作运行成功"
628 self.running_data["status"] = True
629 self.save_running_data()
630
631 def _run_stop_one_step(self, projects: List[dict], sort_idx: int) -> None:
632 j_pro = JavaProject()

Callers 1

stop_groupFunction · 0.95

Calls 6

can_runningMethod · 0.95
save_running_dataMethod · 0.95
build_run_sortMethod · 0.95
_run_stop_one_stepMethod · 0.95
writeFileMethod · 0.80
formatMethod · 0.45

Tested by

no test coverage detected