Administrator
2025-04-23 257bb8ce781ec0ef582092ea8e453ae9aec2a2c4
多余日志删除
4个文件已修改
24 ■■■■ 已修改文件
code_attribute/code_nature_analyse.py 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
code_attribute/first_target_code_data_processor.py 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
huaxin_client/l2_data_manager.py 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
huaxin_client/l2_data_manager_v2.py 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
code_attribute/code_nature_analyse.py
@@ -560,8 +560,8 @@
    items = datas[0 - day_count:]
    for item in items:
        limit_up_price = float(gpcode_manager.get_limit_up_price_by_preprice(code, item["pre_close"]))
        if abs(limit_up_price - item["high"]) < 0.001 and abs(limit_up_price - item["close"]) > 0.001:
            # 炸板
        if abs(limit_up_price - item["high"]) < 0.001:
            # 炸板 # 或涨停
            return True
    return False
code_attribute/first_target_code_data_processor.py
@@ -125,8 +125,12 @@
                if not WantBuyCodesManager().is_in_cache(
                        code) and not gpcode_manager.BuyOpenLimitUpCodeManager().is_in_cache(code):
                    if len(k_format) > 10 and k_format[10]:
                        l2_trade_util.forbidden_trade(code, "近5个交易日有涨停/炸板/跌停")
                        continue
                    # 新题材破前高就不需要加黑
                    need_forbidden = new_block_processor.is_can_forbidden(code)
                    # 新题材该拉黑还是拉黑
                    need_forbidden = True  #new_block_processor.is_can_forbidden(code)
                    if need_forbidden:
                        if code_nature_analyse.is_price_too_high_in_days(code, volumes_data, limit_up_price)[0]:
                            # 判断是否太高
huaxin_client/l2_data_manager.py
@@ -16,7 +16,7 @@
from log_module import async_log_util
from log_module.async_log_util import huaxin_l2_log
from log_module.log import logger_local_huaxin_l2_error, logger_system, logger_local_huaxin_l2_subscript, \
    logger_local_huaxin_l2_special_volume, logger_debug
    logger_local_huaxin_l2_special_volume, logger_debug, logger_local_huaxin_l2_orderdetail
from utils import tool
import collections
import zmq
@@ -55,8 +55,8 @@
            # (最小的量, 涨停价格, 影子单价格, 买的量, 废弃使用, 特殊的量集合)
            self.filter_order_condition_dict[code] = [(min_volume, limit_up_price, shadow_price, buy_volume,
                                                       int(min_volume) // 50, set(special_volumes))]
            huaxin_l2_log.info(logger_local_huaxin_l2_subscript,
                               f"({code})常规过滤条件设置:{self.filter_order_condition_dict[code]}")
            # huaxin_l2_log.info(logger_local_huaxin_l2_subscript,
            #                    f"({code})常规过滤条件设置:{self.filter_order_condition_dict[code]}")
        except Exception as e:
            logger_debug.error(f"{str(e)} - min_volume-{min_volume}")
@@ -192,6 +192,7 @@
    def __run_upload_order_task(self, code):
        q: collections.deque = self.temp_order_queue_dict.get(code)
        temp_list = []
        filter_condition = self.filter_order_condition_dict.get(code)
        while True:
            try:
                while len(q) > 0:
@@ -213,6 +214,11 @@
                    if use_time > 0.01:
                        # 记录10ms以上的数据
                        huaxin_l2_log.info(logger_local_huaxin_l2_error, f"耗时:{use_time}s  结束数据:{last_data}")
                    # 记录所有的订单号
                    if filter_condition:
                        huaxin_l2_log.info(logger_local_huaxin_l2_orderdetail,
                                           f"{[(x[0], x[1], x[2], x[4], x[8]) for x in temp_list if x[2] >= filter_condition[0][0]]}")
                    temp_list = []
                else:
                    if code not in self.temp_order_queue_dict:
huaxin_client/l2_data_manager_v2.py
@@ -70,7 +70,7 @@
            # (最小的量, 涨停价格, 影子单价格, 买的量, 废弃使用, 特殊的量集合)
            self.filter_order_condition_dict[code] = [(min_volume, limit_up_price, shadow_price, buy_volume,
                                                       int(min_volume) // 50, set(special_volumes))]
            logger_local_huaxin_l2_subscript.info(f"({code})常规过滤条件设置:{self.filter_order_condition_dict[code]}")
            # logger_local_huaxin_l2_subscript.info(f"({code})常规过滤条件设置:{self.filter_order_condition_dict[code]}")
        except Exception as e:
            logger_debug.error(f"{str(e)} - min_volume-{min_volume}")