diff --git a/src/py/flwr/cli/app.py b/src/py/flwr/cli/app.py index e73e512eb22b..3e8b233a0928 100644 --- a/src/py/flwr/cli/app.py +++ b/src/py/flwr/cli/app.py @@ -33,7 +33,6 @@ ) app.command()(new) -app.command()(logs) app.command()(example) app.command()(run) app.command()(build) diff --git a/src/py/flwr/superexec/exec_servicer.py b/src/py/flwr/superexec/exec_servicer.py index dc8a960ce151..fc09d5aed28b 100644 --- a/src/py/flwr/superexec/exec_servicer.py +++ b/src/py/flwr/superexec/exec_servicer.py @@ -41,7 +41,7 @@ class ExecServicer(exec_pb2_grpc.ExecServicer): def __init__(self, plugin: Executor) -> None: self.plugin = plugin - self.runs: Dict[int, subprocess.Popen[str]] = {} + self.runs: Dict[int, Popen[str]] = {} self.logs = [] self.lock = threading.Lock() @@ -59,11 +59,12 @@ def StartRun( def _capture_logs(self, proc): select_timeout = 1.0 + def run(): while True: - reads, _, _ = select.select([proc.stdout], [], [], select_timeout) + reads, _, _ = select.select([proc.stderr], [], [], select_timeout) if reads: - line = proc.stdout.readline() + line = proc.stderr.readline() if line: self.logs.append(line.rstrip())