Administrator
2023-09-04 acd3f8f4d658f8261f3a592d7943c065e0b6fc71
trade/current_price_process_manager.py
@@ -22,7 +22,7 @@
latest_add_codes = set()
def accept_prices(prices):
def accept_prices(prices, request_id=None):
    # 获取首板代码
    first_codes = gpcode_manager.FirstGPCodesManager().get_first_gp_codes_cache()
@@ -135,7 +135,7 @@
                if True:
                    print("设置L2代码数量:", len(add_code_set))
                    global latest_add_codes
                    logger_l2_codes_subscript.info(f"预处理新增订阅代码:{add_code_set - latest_add_codes}")
                    logger_l2_codes_subscript.info(f"({request_id})预处理新增订阅代码:{add_code_set - latest_add_codes}")
                    latest_add_codes = add_code_set
                    add_datas = []
                    for d in add_code_list:
@@ -143,7 +143,7 @@
                        limit_up_price = round(float(limit_up_price), 2)
                        min_volume = int(round(50 * 10000 / limit_up_price))
                        add_datas.append((d, min_volume, limit_up_price))
                    huaxin_target_codes_manager.HuaXinL2SubscriptCodesManager.push(add_datas)
                    huaxin_target_codes_manager.HuaXinL2SubscriptCodesManager.push(add_datas, request_id)
            except Exception as e:
                logging.exception(e)
        else: