| | |
| | | # 计算范围到申报时间的那一秒 |
| | | import json |
| | | import logging |
| | | import random |
| | | import time |
| | | |
| | | import constant |
| | |
| | | from l2.code_price_manager import Buy1PriceManager |
| | | from l2.huaxin import l2_huaxin_util |
| | | from l2.l2_data_manager import OrderBeginPosInfo |
| | | from l2.l2_sell_manager import L2LimitUpSellManager |
| | | from l2.l2_transaction_data_manager import HuaXinBuyOrderManager, HuaXinSellOrderStatisticManager, BigOrderDealManager |
| | | from log_module import async_log_util |
| | | from trade.deal_big_money_manager import DealOrderNoManager |
| | | from trade.sell.sell_rule_manager import TradeRuleManager |
| | | |
| | | from utils import tool |
| | |
| | | def __getLimitUpInfo(pidType, page, pageSize): |
| | | data = f"Order=0&a=DailyLimitPerformance&st={pageSize}&apiv=w35&Type=4&c=HomeDingPan&PhoneOSNew=1&DeviceID=a38adabd-99ef-3116-8bb9-6d893c846e24&VerSion=5.13.0.0&Index={(page - 1) * pageSize}&PidType={pidType}&" |
| | | result = __base_request("https://apphq.longhuvip.com/w1/api/index.php", data=data) |
| | | print(result) |
| | | return result |
| | | |
| | | |
| | |
| | | for i in range(100): |
| | | start_time = time.time() |
| | | result = __getLimitUpInfo(pid_info[0], i + 1, 20) |
| | | print("请求用时", time.time() - start_time) |
| | | result = json.loads(result) |
| | | datas = result["info"][0] |
| | | results.extend(datas) |
| | | day = result["info"][1] |
| | | print(datas) |
| | | if len(datas) < 20: |
| | | break |
| | | for r in results: |
| | |
| | | |
| | | |
| | | if __name__ == "__main__": |
| | | print(set(__getConceptJXBK("002670")) - constant.KPL_INVALID_BLOCKS) |
| | | print(getLimitUpInfoNew()) |
| | |
| | | |
| | | import constant |
| | | from db.redis_manager_delegate import RedisUtils |
| | | from log_module import async_log_util |
| | | from log_module import async_log_util, log |
| | | from utils import tool |
| | | |
| | | # 开盘啦历史涨停数据管理 |
| | |
| | | |
| | | @classmethod |
| | | def run_limit_up_task(cls): |
| | | # 关闭log |
| | | log.close_print() |
| | | while True: |
| | | try: |
| | | if (tool.is_trade_time() and int(tool.get_now_time_str().replace(':', '')) > int("092530")): |