python将json数据写入Excel报错AttributeError: ‘Dataset’ object has no attribute ‘xls’
Traceback (most recent call last):
File "c:/xx/xxx/xxx/xxx/xxx.py", line 124, in <module>
example(7)
File "c:/xx/xxx/xxx/xxx/xxx.py", line 119, in example
table.write(file_data.xls)
AttributeError: 'Dataset' object has no attribute 'xls'
因为安装的tablib库没有安装完全,只需要重新装全就行了。
pip install tablib[all]
PS:不需要删除原来的库