From 48dfbb49e7e7fdcb13e5cb650484f4fbaed938a7 Mon Sep 17 00:00:00 2001 From: Ardian Date: Tue, 18 Jun 2024 10:59:49 +0200 Subject: [PATCH] temp: add binary --- operate/services/service.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/operate/services/service.py b/operate/services/service.py index e9cefdca6..f96e3f3cf 100644 --- a/operate/services/service.py +++ b/operate/services/service.py @@ -25,6 +25,7 @@ import shutil import signal import subprocess # nosec +import sys import time import typing as t from copy import copy, deepcopy @@ -385,7 +386,7 @@ def _setup_agent(working_dir: Path) -> None: encoding="utf-8", ) - abin = 'aea_bin' + abin = str(Path(sys._MEIPASS) / 'aea_bin') # Fetch agent _run_cmd( args=[ @@ -430,7 +431,7 @@ def _setup_agent(working_dir: Path) -> None: def _start_agent(working_dir: Path) -> None: """Start agent process.""" env = json.loads((working_dir / "agent.json").read_text(encoding="utf-8")) - aea_bin = 'aea_bin' + aea_bin = str(Path(sys._MEIPASS) / 'aea_bin') process = subprocess.Popen( # pylint: disable=consider-using-with # nosec args=[aea_bin, "run"], cwd=working_dir / "agent", @@ -450,7 +451,7 @@ def _start_agent(working_dir: Path) -> None: def _start_tendermint(working_dir: Path) -> None: """Start tendermint process.""" env = json.loads((working_dir / "tendermint.json").read_text(encoding="utf-8")) - tendermint_com = "tendermint" + tendermint_com = str(Path(sys._MEIPASS) / "tendermint") process = subprocess.Popen( # pylint: disable=consider-using-with # nosec args=[tendermint_com], cwd=working_dir,