Skip to content
Snippets Groups Projects
Commit b836ed66 authored by Charlotte Hausman's avatar Charlotte Hausman
Browse files

fix pass/fail with mutable version bug

parent af65fe4c
No related branches found
No related tags found
3 merge requests!1059Catchup 2.7 with main,!1058Draft: Rebase 2.7 on main,!1005fix pass/fail with mutable version bug
Pipeline #6065 passed
Pipeline: workspaces

#6067

    Pipeline: workspaces

    #6066

      ......@@ -539,15 +539,23 @@ class QaPass(Action):
      @staticmethod
      def check_still_running(version: CapabilityVersion) -> bool:
      workflow_service_url = CapoConfig().settings(WORKFLOW_SETTINGS_KEY).serviceUrl
      if version.current_execution.current_workflow_request_id:
      response = requests.get(
      f"{workflow_service_url}/workflows/{version.capability.name}/requests/"
      f"{version.current_execution.current_workflow_request_id}/htcondor_id"
      )
      if json.loads(response.content.decode())["htcondor_job_id"] == "None":
      # check for execution
      if version.current_execution:
      # version is submitted, check for workflow
      if version.current_execution.current_workflow_request_id:
      response = requests.get(
      f"{workflow_service_url}/workflows/{version.capability.name}/requests/"
      f"{version.current_execution.current_workflow_request_id}/htcondor_id"
      )
      if json.loads(response.content.decode())["htcondor_job_id"] == "None":
      # not running in HTCondor
      return False
      return True
      else:
      # workflow not submitted
      return False
      return True
      else:
      # version is not submitted
      return False
      @staticmethod
      ......
      0% Loading or .
      You are about to add 0 people to the discussion. Proceed with caution.
      Finish editing this message first!
      Please register or to comment