inited_data.py | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
l2/cancel_buy_strategy.py | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
servers/huaxin_trade_server.py | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
trade/buy_radical/block_special_codes_manager.py | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
inited_data.py
@@ -10,6 +10,7 @@ from l2.l2_sell_manager import L2MarketSellManager from l2.l2_transaction_data_manager import HuaXinBuyOrderManager from third_data.third_blocks_manager import InvalidBlockManager, CodeThirdBlocksManager from trade.buy_money_count_setting import BuyMoneyAndCountSetting from trade.deal_big_money_manager import DealOrderNoManager from trade.trade_manager import AutoCancelSellModeManager from utils import tool @@ -43,6 +44,10 @@ CodeThirdBlocksManager() BuyMoneyAndCountSetting() gpcode_manager.WantBuyCodesManager() # 9点25之前删除所有代码 if tool.trade_time_sub(tool.get_now_time_str(), "09:25:00") <= 0: # 删除L2监听代码 l2/cancel_buy_strategy.py
@@ -520,9 +520,11 @@ if dealing_info and str(dealing_info[0]) == str(val["orderNo"]): total_left_num -= dealing_info[1] // 100 limit_up_price = gpcode_manager.get_limit_up_price(code) if total_left_count <= 1 or (total_left_count <= THRESHOLD_COUNT and limit_up_price and total_left_num * float( limit_up_price) < THRESHOLD_MONEY_W * 100): return True, f"剩余笔数({total_left_count})/金额({round(total_left_num * float(limit_up_price) * 100)})不足,成交进度:{trade_index},真实下单位置:{real_order_index} 阈值:({THRESHOLD_MONEY_W},{THRESHOLD_COUNT}) " total_left_money = total_left_num * float(limit_up_price)*100 if total_left_money < 1e8: if total_left_count <= 1 or (total_left_count <= THRESHOLD_COUNT and limit_up_price and total_left_num * float( limit_up_price) < THRESHOLD_MONEY_W * 100): return True, f"剩余笔数({total_left_count})/金额({round(total_left_num * float(limit_up_price) * 100)})不足,成交进度:{trade_index},真实下单位置:{real_order_index} 阈值:({THRESHOLD_MONEY_W},{THRESHOLD_COUNT}) " return False, f"不满足撤单条件: 成交进度-{trade_index} 真实下单位置-{real_order_index} total_left_count-{total_left_count} total_left_num-{total_left_num}" # 距离太近,封单不足 servers/huaxin_trade_server.py
@@ -1131,6 +1131,10 @@ # except: # pass # 初始化数据 BuyMoneyAndCountSetting() gpcode_manager.WantBuyCodesManager() def run(queue_strategy_r_trade_w, queue_strategy_w_trade_r, queue_strategy_w_trade_r_for_read, trade_ipc_addr): """ trade/buy_radical/block_special_codes_manager.py
@@ -53,7 +53,7 @@ self.__code_blocks_dict[code] = set() self.__code_blocks_dict[code].add(block) if code not in self.__block_codes_dict: if block not in self.__block_codes_dict: self.__block_codes_dict[block] = set() self.__block_codes_dict[block].add(code)