Set `.bs_mktid` on all IB position-msg emissions..

qt_w_graceful_SIGINT
Tyler Goodlet 2025-09-26 17:44:06 -04:00
parent 9ea857298c
commit ad3fe65bd9
1 changed files with 6 additions and 1 deletions

View File

@ -358,6 +358,10 @@ async def update_and_audit_pos_msg(
size=ibpos.position,
avg_price=pikerpos.ppu,
# XXX ensures matching even if multiple venue-names
# in `.bs_fqme`, likely from txn records..
bs_mktid=mkt.bs_mktid,
)
ibfmtmsg: str = pformat(ibpos._asdict())
@ -426,7 +430,8 @@ async def aggr_open_orders(
) -> None:
'''
Collect all open orders from client and fill in `order_msgs: list`.
Collect all open orders from client and fill in `order_msgs:
list`.
'''
trades: list[Trade] = client.ib.openTrades()