chore: improve optimize reports stability

This commit is contained in:
Matthias
2026-01-02 18:23:00 +01:00
parent cbd1a4c060
commit 7b49dc8c11
@@ -287,9 +287,9 @@ def text_table_add_metrics(strat_results: dict) -> None:
if "trading_mode" in strat_results
else []
)
wallet_metrics: list[tuple[str, str]] = []
if wallet_stats := strat_results.get("wallet_stats"):
wallet_metrics = (
wallet_metrics = [
(
"Min/Max balance realized",
f"{fmt_coin(strat_results['csum_min'], stake)} / "
@@ -304,7 +304,7 @@ def text_table_add_metrics(strat_results: dict) -> None:
"Min/Max balance dates",
f"{wallet_stats['low_date']} / {wallet_stats['high_date']}",
),
)
]
# Newly added fields should be ignored if they are missing in strat_results. hyperopt-show
# command stores these results and newer version of freqtrade must be able to handle old