From 60ea9ab80249a2dc4432f25085a62147a98a8ac3 Mon Sep 17 00:00:00 2001 From: Bill Date: Tue, 4 Nov 2025 09:51:52 -0500 Subject: [PATCH] fix: use get_db_path for deployment mode compatibility in get_current_position_from_db --- agent_tools/tool_trade.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/agent_tools/tool_trade.py b/agent_tools/tool_trade.py index 6fa9429..32ccaa6 100644 --- a/agent_tools/tool_trade.py +++ b/agent_tools/tool_trade.py @@ -17,6 +17,7 @@ from tools.price_tools import get_open_prices import json from api.database import get_db_connection from datetime import datetime, timezone +from tools.deployment_config import get_db_path mcp = FastMCP("TradeTools") @@ -43,7 +44,7 @@ def get_current_position_from_db( - position_dict: {"AAPL": 10, "MSFT": 5, "CASH": 8500.0} - action_count: Number of holdings (for action_id tracking) """ - db_path = "data/trading.db" + db_path = get_db_path("data/jobs.db") conn = get_db_connection(db_path) cursor = conn.cursor()