summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKirill Rysin <[email protected]>2025-07-23 16:35:54 +0200
committerGitHub <[email protected]>2025-07-23 14:35:54 +0000
commit674119ec63510afcccbc4284e9b682f7deb125f6 (patch)
tree37949ed1c258acaac7b3cf4b8e1cb47190e79aef
parent525bcce317cb9f94075675ce344a96adf04eecb7 (diff)
Nemesis: fix stucking perform_checks (#21548)
-rw-r--r--ydb/tests/library/nemesis/remote_execution.py30
1 files changed, 15 insertions, 15 deletions
diff --git a/ydb/tests/library/nemesis/remote_execution.py b/ydb/tests/library/nemesis/remote_execution.py
index 556d7f093f8..fe6f35dd5cd 100644
--- a/ydb/tests/library/nemesis/remote_execution.py
+++ b/ydb/tests/library/nemesis/remote_execution.py
@@ -54,23 +54,23 @@ def wait_timeout(process, timeout):
def execute_command_with_output_on_hosts(list_of_hosts, command, per_host_timeout=60, username=None):
full_output = []
full_retcode = 0
- pool = futures.ProcessPoolExecutor(8)
- fs = []
- for host in list_of_hosts:
- fs.append(
- pool.submit(
- execute_command_with_output_single_host,
- host, command,
- timeout=per_host_timeout,
- username=username
+ with futures.ProcessPoolExecutor(8) as pool:
+ fs = []
+ for host in list_of_hosts:
+ fs.append(
+ pool.submit(
+ execute_command_with_output_single_host,
+ host, command,
+ timeout=per_host_timeout,
+ username=username
+ )
)
- )
- for f in fs:
- retcode, output = f.result()
- if retcode:
- full_retcode = retcode
- full_output.extend(output)
+ for f in fs:
+ retcode, output = f.result()
+ if retcode:
+ full_retcode = retcode
+ full_output.extend(output)
return full_retcode, full_output