RKDN / bgg_collection2pdf

Generate a PDF catalog of your boardgamegeek.com collection.
MIT License
24 stars 9 forks source link

"/usr/lib/python3.9/xml/etree/ElementTree.py", line 1348 throws exception with Python 3.9 #7

Closed RKDN closed 2 years ago

RKDN commented 2 years ago

There may be something that can be done to patch this issue in the script. However, it seems to be occurring in ElementTree.py

I'm unable to reproduce the issue with Python 3.10.2

WARNING:root:UserName: was not valid
Enter your BGG UserName: packrat84
INFO:root:UserName: packrat84 is valid
INFO:root:starting
WARNING:root:Reading ./collection.xml
Traceback (most recent call last):
File "/mnt/c/users/frankk/OneDrive/Boredgames/BGG/bgg_collection2pdf/generate_pdf.py", line 391, in <module>
thisgameitems = ElementTree.fromstring(file.read())
File "/usr/lib/python3.9/xml/etree/ElementTree.py", line 1348, in XML
return parser.close()
xml.etree.ElementTree.ParseError: no element found: line 1, column 0
RKDN commented 2 years ago

This was resolved by the user deleting XML files created by an old version of the application.