Skip to content

Commit

Permalink
Further improved the comparison str generated between baseline/compar…
Browse files Browse the repository at this point in the history
…ison data
  • Loading branch information
filipecosta90 committed Oct 25, 2023
1 parent b753834 commit 4fab841
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "redisbench-admin"
version = "0.10.17"
version = "0.10.18"
description = "Redis benchmark run helper. A wrapper around Redis and Redis Modules benchmark tools ( ftsb_redisearch, memtier_benchmark, redis-benchmark, aibench, etc... )."
authors = ["filipecosta90 <filipecosta.90@gmail.com>","Redis Performance Group <performance@redis.com>"]
readme = "README.md"
Expand Down
7 changes: 6 additions & 1 deletion redisbench_admin/compare/compare.py
Original file line number Diff line number Diff line change
Expand Up @@ -960,7 +960,12 @@ def check_multi_value_filter(baseline_str):


def prepare_value_str(baseline_pct_change, baseline_v, baseline_values, simplify_table):
baseline_v_str = " {:.0f}".format(baseline_v)
if baseline_v < 1.0:
baseline_v_str = " {:.2f}".format(baseline_v)
elif baseline_v < 10.0:
baseline_v_str = " {:.1f}".format(baseline_v)
else:
baseline_v_str = " {:.0f}".format(baseline_v)
stamp_b = ""
if baseline_pct_change > 10.0:
stamp_b = "UNSTABLE "
Expand Down
8 changes: 6 additions & 2 deletions redisbench_admin/run_remote/remote_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -286,8 +286,12 @@ def post_process_remote_run(
start_time_str,
stdout,
)
with open(local_benchmark_output_filename, "r") as json_file:
results_dict = json.load(json_file)
try:
with open(local_benchmark_output_filename, "r") as json_file:
results_dict = json.load(json_file)
except json.decoder.JSONDecodeError as e:
logging.error("Received error while decoding JSON: {}".format(e.__str__()))
pass
# check KPIs
return_code = results_dict_kpi_check(benchmark_config, results_dict, return_code)
# if the benchmark tool is redisgraph-benchmark-go and
Expand Down

0 comments on commit 4fab841

Please sign in to comment.