| | |
| | | |
| | | if records: |
| | | cls.latest_origin_datas = records |
| | | cls.__LimitUpCodesPlateKeyManager.set_today_limit_up([(r[0], r[5]) for r in records]) |
| | | cls.__LimitUpCodesPlateKeyManager.set_today_limit_up([(r[0], r[5], r[6].split('、') if r[6] else []) for r in records]) |
| | | |
| | | code_reasons_dict = {} |
| | | reason_codes_dict = {} |
| | |
| | | @classmethod |
| | | def load_total_datas(cls): |
| | | cls.total_datas = KPLLimitUpDataRecordManager.list_all(tool.get_now_date_str()) |
| | | cls.__LimitUpCodesPlateKeyManager.set_today_total_limit_up([(r[3], r[2]) for r in cls.total_datas]) |
| | | cls.__LimitUpCodesPlateKeyManager.set_today_total_limit_up([(r[3], r[2], r[6].split("、") if r[6] else []) for r in cls.total_datas]) |
| | | for d in cls.total_datas: |
| | | cls.__load_hist_and_blocks(d[3]) |
| | | |
| | |
| | | |
| | | def get_limit_up(): |
| | | while True: |
| | | if (tool.is_trade_time() and int(tool.get_now_time_str().replace(':', '')) > int("092530")) or True: |
| | | try: |
| | | try: |
| | | if (tool.is_trade_time() and int(tool.get_now_time_str().replace(':', '')) > int("092530")): |
| | | results = kpl_api.getLimitUpInfoNew() |
| | | result = json.loads(results) |
| | | start_time = time.time() |
| | | __upload_data("limit_up", result) |
| | | except Exception as e: |
| | | except Exception as e: |
| | | try: |
| | | logging.exception(e) |
| | | time.sleep(3) |
| | | logger_debug.exception(e) |
| | | except: |
| | | pass |
| | | except: |
| | | pass |
| | | finally: |
| | | time.sleep(3) |
| | | |
| | | def get_bidding_money(): |
| | | # 竞价数据上传 |