You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Previously close_position(..., fill_price=X) was silently swallowed by
**kwargs while the DB wrote the simulated exit_price — broker and ledger
drifted on every exit.
- AlpacaBroker.close_position drops the **kwargs sink; docstring documents
that callers must poll get_order(order.id) for the actual filled_avg_price
- _poll_exit_fill(order_id, symbol, timeout=30s) added; 1s interval, returns
actual Alpaca fill price, logs timeout/terminal status
- 3 exit sites now poll and write the actual fill + re-derive net_pnl
with direction-aware sign (short-safe for future short configs):
run_daily main exit path (simulate_exit)
_monitor_close (intraday stop/target hits)
_process_exits (scheduled & forced exits incl. partial T1)
- WARN-level "paper_engine_exit_fill_drift" when actual vs simulated
diverges >0.5% so drift is visible in logs even when non-pathological
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
4 months ago | |
|---|---|---|
| .. | ||
| backtester | 4 months ago | |
| experiment | 4 months ago | |
| intraday_bt | 4 months ago | |
| orb_trader | 4 months ago | |
| overfit | 4 months ago | |
| paper_trader | 4 months ago | |
| pipeline | 4 months ago | |
| qa | 5 months ago | |
| review | 5 months ago | |
| scenario | 5 months ago | |
| sync | 5 months ago | |
| tools | 4 months ago | |
| tracker | 4 months ago | |
| web | 4 months ago | |
| web_frontend | 4 months ago | |
| __init__.py | 5 months ago | |