@devries-cameron20 / open-alice / commits / 40ccbbd
Fork 0

Alice — an open-source AI trading bot covering equities, crypto, commodities, forex, and macro

Live trading: confirm before real orders, add --yes to skip

Camo67 committed Oct 12, 2026 at 17:02 UTC 40ccbbd98634dbdb556d771b838299d31e921725
1 file changed +8
src/open_alice/cli.py
+8
@@ -73,6 +73,7 @@ def main() -> None:
73 live.add_argument("--risk", type=float, default=0.02, help="Risk per trade")
74 live.add_argument("--interval", type=int, default=60, help="Check interval (seconds)")
75 live.add_argument("--execute", action="store_true", help="Actually place orders")
76 + live.add_argument("--yes", action="store_true", help="Skip the live-orders confirmation")
77
78 # Broker account management (Headway via MT5)
79 broker = subparsers.add_parser("broker", help="Manage MT5 / Headway login")
@@ -378,6 +379,13 @@ def _run_live(args: argparse.Namespace) -> None:
379 sys.exit(1)
380
381 execute = bool(getattr(args, "execute", False))
382 + if execute and not bool(getattr(args, "yes", False)):
383 + print(" WARNING: --execute places REAL orders on your Headway account.")
384 + confirm = input(" Type YES to continue with live orders: ").strip()
385 + if confirm != "YES":
386 + print(" Aborted. Re-run without --execute for a dry run.")
387 + broker.disconnect()
388 + return
389 try:
390 strategy = _build_strategy(args.strategy, args)
391