feat(execution): AccountOrderWorker로 매수·매도 주문 직렬화

전략별 tick/scan 매도 락 대신 계좌 단일 PriorityQueue로 place를 B-full 직렬화한다.
틱매도 only_code 필터와 inflight 중복 enqueue 방지로 REST 폭주를 줄인다.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Your Name
2026-08-28 16:45:26 +09:00
parent ffe84a9375
commit bc2b1b642c
15 changed files with 541 additions and 207 deletions

View File

@@ -459,7 +459,7 @@ class TailCatchStrategy(BaseStrategy):
# ------------------------------------------------------------------
# 매도
# ------------------------------------------------------------------
def check_sell_signals(self) -> List[Dict]:
def check_sell_signals(self, only_code: Optional[str] = None) -> List[Dict]:
if not self.holdings or te is None:
return []
@@ -477,6 +477,8 @@ class TailCatchStrategy(BaseStrategy):
signals: List[Dict] = []
for code, holding in list(self.holdings.items()):
if only_code and code != only_code:
continue
try:
name = holding.get("name", code)
buy_price = float(holding.get("buy_price", 0))