Warning(fromwarningsmodule):File"C:\Python27\lib\site-packages\openpyxl\styles\styleable.py",line111warn("Useformattingobjectssuchasfontdirectly")UserWarning:Useformattin...
Warning (from warnings module):
File "C:\Python27\lib\site-packages\openpyxl\styles\styleable.py", line 111
warn("Use formatting objects such as font directly")
UserWarning: Use formatting objects such as font directly
Warning (from warnings module):
File "C:\Python27\lib\site-packages\openpyxl\styles\__init__.py", line 52
def copy(self):
UserWarning: Call to deprecated function or class copy (Copy formatting objects like font directly).
Traceback (most recent call last):
File "E:\moving\Python_script\selenium_s\zuanzhan\report.py", line 53, in
main()
File "E:\moving\Python_script\selenium_s\zuanzhan\report.py", line 48, in main
df2.to_excel(ew,word,index=None,columns=cols)
File "C:\Python27\lib\site-packages\pandas\util\decorators.py", line 88, in wrapper
return func(*args, **kwargs)
File "C:\Python27\lib\site-packages\pandas\core\frame.py", line 1260, in to_excel
startrow=startrow, startcol=startcol)
File "C:\Python27\lib\site-packages\pandas\io\excel.py", line 696, in write_cells
xcell.style = xcell.style.copy(**style_kwargs)
File "C:\Python27\lib\site-packages\openpyxl\compat\__init__.py", line 67, in new_func
return obj(*args, **kwargs)
TypeError: copy() got an unexpected keyword argument 'font'
展开