Skip to content
This repository has been archived by the owner on Apr 15, 2020. It is now read-only.

PYTDX DEBUG hit exception on req exception is 'gbk' codec can't decode byte #197

Open
matakk opened this issue Feb 9, 2019 · 2 comments

Comments

@matakk
Copy link

matakk commented Feb 9, 2019

你好,请教一个问题:我循环一个股票的所有f10数据的时候,有些无法获取到
data_f10_list = api.get_company_info_category(market, code)
for v in data_f10_list:
data = api.get_company_info_content(market, code,v['filename'], v['start'], v['length'])
if data == None:
continue --->有些进入到这里面。

debug输出是:
2019-02-09 19:45:41,390 - PYTDX - DEBUG - hit exception on req exception is 'gbk' codec can't decode byte 0xbc in position 30719: incomplete multibyte sequence

错误股票是:MARKET_SZ, '000001',是“重大事项”字段,是我的编码设置的问题吗?
我的目的是循环把所有数据下载下来。

@rainx
Copy link
Owner

rainx commented Aug 24, 2019

@matakk 此问题还在么?能否给出一下你出错的时候的 所连接的服务器以及 v['filename'], v['start'], v['length'] 三个参数的数值供参考

@matakk
Copy link
Author

matakk commented Sep 4, 2019

谢谢,我忘记了怎么改的了,估计是python开头加了一下 codec的声明,就解决了。

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants