diff --git a/tests/integration/instant_benchmark.py b/tests/integration/instant_benchmark.py index 3d0f3ed0dc..365c421894 100644 --- a/tests/integration/instant_benchmark.py +++ b/tests/integration/instant_benchmark.py @@ -247,14 +247,16 @@ def build_running_script(template, job, instance, record): job_template['requirements'], job_template['env']) container = job_template['container'] - benchmark_command = [] + benchmark_command = ['set -x'] record_benchmark = ('python3 record_benchmark.py --template template.json ' f'--job {job} --instance {instance} ' f'--model models/test --record {record}') for key, value in job_template['awscurl'].items(): + benchmark_command.append("rm -rf benchmark_result.json benchmark.log") benchmark_command.append(value) - benchmark_command.append(record_benchmark + f' --benchmark-vars "{key}"') + benchmark_command.append(record_benchmark + + f' --benchmark-vars "{key}"') bash_command = [ 'set -euo pipefail', diff --git a/tests/integration/record_benchmark.py b/tests/integration/record_benchmark.py index df6cdcaeba..a7a8697f19 100755 --- a/tests/integration/record_benchmark.py +++ b/tests/integration/record_benchmark.py @@ -124,7 +124,9 @@ def data_basic(data: dict): def data_from_client(data: dict): if os.path.exists("benchmark_result.json"): with open("benchmark_result.json", "r") as f: - data.update(json.load(f)) + benchmark_metrics = json.load(f) + data.update(benchmark_metrics) + print(f"found awscurl metrics json: {benchmark_metrics}") elif os.path.exists("benchmark.log"): with open("benchmark.log", "r") as f: for line in f.readlines():