- fix: inactivity watchdog now waits 30s for HTML report then kills
terminal64.exe unconditionally — ShutdownTerminal=1 does not cause
MT5 to exit on Wine/macOS; relying on natural exit caused all runs
to fall back to journal extraction
- fix: tester agent log deduplication — each deal is written twice in
the log; use HashSet to skip already-seen deal numbers
- fix: position tracker for entry direction inference — infer "in"/"out"
from per-symbol signed lot accumulation instead of guessing
- fix: is_closed_trade() no longer gates on profit!=0.0 — journal deals
have profit=0.0 legitimately; the old gate hid all 140 deals from
list_deals
- fix: log file selection priority — prefer Agent-127.0.0.1 over
Agent-0.0.0.0 (startup-only log), tiebreak by file size
- feat: launch_backtest default shutdown=true; inactivity_kill_secs
default 120s exposed as tool parameter
- feat: report DB stores deals in SQLite; analytics resolve by
report_id / report_dir / latest
Verified: 1-month DPS21/XAUUSD.cent/M5 backtest produces full HTML
report with all metrics (win_rate=70%, profit_factor=0.77, sharpe=-3.61,
max_dd=6.93%) and all 17 analytics tools returning real data.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Changes to src/compile/mql_compiler.rs:
- Stage compilation to /tmp/mt5_compile_{ea}/ to avoid spaces in paths
(Wine /compile: chokes on spaces in paths like 'Application Support')
- Use bare /log flag - writes log adjacent to source instead of custom path
- Remove host_to_wine_path() conversion - use Unix paths directly
- Simplify MetaEditor invocation (no shell script on Linux)
- Clean up error handling logic
Fixes compilation failures when MT5 is installed in paths containing spaces.
- Add fallback error message with log excerpt when .ex5 missing but no errors parsed
- Include raw log excerpt when few errors detected for better debugging
- Ensures users always see actionable error info when compilation fails