I have a script that I used to be quite proud of, up until today it was working great. Basically it reads in a directory tree of spreadsheets, extracts info from them then makes a new spreadsheet to output the info to. The spreadsheets are xls files so it uses xlrd and xlwt to manage the data extraction and spreadsheet creation. Today when I ran it (after a hiatus of about 3 months) I got this output:
Traceback (most recent call last): File "./cttOverviewMain.0.03.2011.py", line 294, in <module> monthData(searchList) File "./cttOverviewMain.0.03.2011.py", line 261, in monthData writeMonthlyHeader(writeSheet) File "./cttOverviewMain.0.03.2011.py", line 183, in writeMonthlyHeader sh.write(7,10,"# Locations",xlwt.easyxf('font: bold True')) File "/usr/local/lib/python2.6/dist-packages/xlwt/Worksheet.py", line 1003, in write self.row(r).write(c, label, style) File "/usr/local/lib/python2.6/dist-packages/xlwt/Row.py", line 227, in write style_index = self.__parent_wb.add_style(style) File "/usr/local/lib/python2.6/dist-packages/xlwt/Workbook.py", line 303, in add_style return self.__styles.add(style) File "/usr/local/lib/python2.6/dist-packages/xlwt/Style.py", line 90, in add return self._add_style(style)[1] File "/usr/local/lib/python2.6/dist-packages/xlwt/Style.py", line 149, in _add_style raise ValueError("More than 4094 XFs (styles)") ValueError: More than 4094 XFs (styles) I don't understand this very well at all - any pointers are appreciated. I think what it is saying is that there is a problem with my Python libraries but this is not a problem I have ever seen before. Is it possible the 2.6 libraries were updated in the hiatus time causing this problem? If so any ideas on how I can investigate fixing this are appreciated. thomas _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor