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:
@@ -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))
|
||||
|
||||
Reference in New Issue
Block a user