python - xlrd error when opening Excel files with named ranges -
i'm getting following error message when attempting open workbook using xlrd 0.9.1 on python 3.2.4. tested see causing issue , i've troubleshooted spreadsheet having named ranges.
traceback (most recent call last): file "c:\users\mandroid\desktop\xltest.py", line 5, in <module> book = open_workbook(pth) file "c:\python32\lib\site-packages\xlrd\__init__.py", line 416, in open_workbook ragged_rows=ragged_rows, file "c:\python32\lib\site-packages\xlrd\xlsx.py", line 725, in open_workbook_2007_xml x12book.process_stream(zflo, 'workbook') file "c:\python32\lib\site-packages\xlrd\xlsx.py", line 251, in process_stream meth(self, elem) file "c:\python32\lib\site-packages\xlrd\xlsx.py", line 346, in do_defined_names self.do_defined_name(child) file "c:\python32\lib\site-packages\xlrd\xlsx.py", line 335, in do_defined_name nobj.formula_text = cooked_text(self, elem) file "c:\python32\lib\site-packages\xlrd\xlsx.py", line 130, in cooked_text return unicode(unescape(t)) typeerror: <lambda>() takes 2 arguments (1 given)
from i've read, looks xlrd has named range functionality, i'm not sure causing this. appreciated.
it's bug in xlrd 0.9.1: https://github.com/python-excel/xlrd/issues/47
you can try 0.9.0, wait 0.9.2, or apply fix john machin suggests in report.
Comments
Post a Comment