yutiansut / QUANTAXIS

QUANTAXIS 支持任务调度 分布式部署的 股票/期货/期权 数据/回测/模拟/交易/可视化/多账户 纯本地量化解决方案
https://yutiansut.github.io/QUANTAXIS/
MIT License
8.25k stars 2.97k forks source link

无法获取通达信板块数据,Error save_tdx.QA_SU_save_stock_block exception #1812

Open zhlgh603 opened 2 years ago

zhlgh603 commented 2 years ago

2022-09-14 16:46:50,034 - root - WARNING - ##JOB09 Now Saving STOCK_BlOCK ==== QUANTAXIS>> ##JOB09 Now Saving STOCK_BlOCK ==== 2022-09-14 16:47:14,068 - root - WARNING - Selecting the Best Server IP of TDX QUANTAXIS>> Selecting the Best Server IP of TDX USING DEFAULT STOCK IP USING DEFAULT FUTURE IP 2022-09-14 16:47:14,395 - root - WARNING - === The BEST SERVER === stock_ip 119.147.164.60 future_ip 47.107.75.159 QUANTAXIS>> === The BEST SERVER === stock_ip 119.147.164.60 future_ip 47.107.75.159 2022-09-14 16:47:50,733 - root - WARNING - unpack requires a buffer of 2 bytes QUANTAXIS>> unpack requires a buffer of 2 bytes Error save_tdx.QA_SU_save_stock_block exception!

QingYong commented 1 year ago

QATdx.py data = pd.concat([ api.to_df(api.get_and_parse_block_info("block.dat" )).assign(type="yb"), api.to_df(api.get_and_parse_block_info("block_fg.dat")).assign(type="fg"), api.to_df(api.get_and_parse_block_info("block_gn.dat")).assign(type="gn"), api.to_df(api.get_and_parse_block_info("block_zs.dat")).assign(type="zs"),

api.to_df(api.get_and_parse_block_info("hkblock.dat" )).assign(type="hk"),

        # api.to_df(api.get_and_parse_block_info("jjblock.dat" )).assign(type="jj"),
        # api.to_df(api.get_and_parse_block_info("mgblock.dat" )).assign(type="mg"),
        # api.to_df(api.get_and_parse_block_info("sbblock.dat" )).assign(type="sb"),
        # api.to_df(api.get_and_parse_block_info("spblock.dat" )).assign(type="sp"),
        # api.to_df(api.get_and_parse_block_info("ukblock.dat" )).assign(type="uk"),
    ], sort=False)

试试