From 4abc9161d75be2d4a180884137ca45b98af6498d Mon Sep 17 00:00:00 2001 From: Zhaofeng Zhang <24791380+vcfgv@users.noreply.github.com> Date: Mon, 1 Dec 2025 17:45:42 +0800 Subject: [PATCH] fix(strategy): calculate total PnL percentage correctly in portfolio summary --- python/valuecell/server/services/strategy_service.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/valuecell/server/services/strategy_service.py b/python/valuecell/server/services/strategy_service.py index 1e9aaa295..a2dfc87ea 100644 --- a/python/valuecell/server/services/strategy_service.py +++ b/python/valuecell/server/services/strategy_service.py @@ -130,7 +130,7 @@ async def get_strategy_portfolio_summary( cash=_to_optional_float(snapshot.cash), total_value=total_value, total_pnl=total_pnl, - total_pnl_pct=total_pnl_pct, + total_pnl_pct=_to_optional_float(total_pnl_pct) * 100.0, gross_exposure=_to_optional_float( getattr(snapshot, "gross_exposure", None) ),