mirror of
https://github.com/Xe138/AI-Trader.git
synced 2026-04-01 17:17:24 -04:00
Fixed critical bug where ModelDayExecutor._initialize_agent() created a BaseAgent but never called agent.initialize(), leaving self.model=None. This caused 'NoneType' object has no attribute 'bind' error when run_trading_session() tried to create the langchain agent. Changes: - Made _initialize_agent() async - Added await agent.initialize() call - Updated call site to await async function Now properly initializes MCP client, tools, and AI model before executing trading sessions, matching the working CLI mode pattern.
16 KiB
16 KiB