fix(accounting): store net PnL (payout - net_cost) in close_pnl, migrate Paxton record from gross to net
CI/CD / build-and-push (push) Successful in 7s
CI/CD / build-and-push (push) Successful in 7s
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
c5ffc37820
commit
060fc89953
+1
-1
@@ -313,7 +313,7 @@ async def get_summary():
|
||||
# unrealized_pnl_est: open positions, edge_net × net_cost − fee.
|
||||
# Estimated — uses model signal, not live price. Source: open trades.
|
||||
# realized_pnl: closed positions with known resolution.
|
||||
# Exact — computed from (resolution − entry_price) × shares.
|
||||
# Exact — payout − net_cost per trade (net of fee), matches logs/Telegram.
|
||||
# total_pnl: sum of both.
|
||||
"unrealized_pnl_est": latest.get("unrealized_pnl_est") or 0,
|
||||
"realized_pnl": latest.get("realized_pnl") or 0,
|
||||
|
||||
Reference in New Issue
Block a user