From 87103d9325be0601b6f33eab737fc541b56e9577 Mon Sep 17 00:00:00 2001 From: Administrator <admin@example.com> Date: 星期三, 27 三月 2024 12:32:36 +0800 Subject: [PATCH] bug修复 --- test/test_sell.py | 34 +++++++++++++++++++++++++++++----- 1 files changed, 29 insertions(+), 5 deletions(-) diff --git a/test/test_sell.py b/test/test_sell.py index 6c20b11..8e1addf 100644 --- a/test/test_sell.py +++ b/test/test_sell.py @@ -1,7 +1,31 @@ -from trade.sell import sell_manager +from l2.l2_transaction_data_manager import HuaXinSellOrderStatisticManager +from log_module import log_export, async_log_util +from utils import tool + + +def load_sell_info(): + date = tool.get_now_date_str() + data_map = log_export.load_huaxin_transaction_map(date=date) + for code in data_map: + if code != '002562': + continue + datas = data_map[code] + for d in datas: + big_sell_order_info = HuaXinSellOrderStatisticManager.add_transaction_datas(code, d) + async_log_util.run_sync() + + +def test_sell_order_info(): + code = "002562" + date = tool.get_now_date_str() + data_map = log_export.load_huaxin_transaction_map(date=date) + datas = data_map.get(code) + for d in datas: + big_sell_order_info = HuaXinSellOrderStatisticManager.add_transaction_datas(code, d) + if big_sell_order_info[0] < 50 * 10000: + continue + print(big_sell_order_info) + if __name__ == '__main__': - code = "000333" - __HumanSellManager = sell_manager.HumanSellManager() - f = __HumanSellManager.distribute_sell_volume(code, 2000) - print(f) + test_sell_order_info() -- Gitblit v1.8.0