HuobiRDCenter / huobi_Python

Python SDK for Huobi Spot API
https://huobiapi.github.io/docs/spot/v1/en
Apache License 2.0
680 stars 332 forks source link

升级到python3.9后,遇到 TypeError: __init__() got an unexpected keyword argument 'encoding' 错误 #111

Open cmdyu opened 3 years ago

cmdyu commented 3 years ago

参考
https://github.com/psychopy/psychopy/pull/3343

把 huobi/connection/impl/restapi_invoker.py 第56行里的 encoding 参数去掉后就可以了,如下

dict_data = json.loads(response.text)

codertesla commented 3 years ago

遇到同样的错误。

我操作了以下两个步骤后成功读取数据:

  1. 搜索删除文件huobi/connection/impl/restapi_invoker.py encoding 参数,总共4处;
  2. 按照安装说明,重装一遍 huobi sdk;

总结:这坑请官方尽快填上。