[XML-SIG] Re: Bug in ElementTree (or in my xml file )?

lienard.bruno at free.fr lienard.bruno at free.fr
Sun Apr 17 22:06:09 CEST 2005

FixXml.py is the name of the script, I have sent it from Pythonwin. I have the
same result when I launch it from the dos prompt

C:\Test0\FineReader>c:\python23\python FixXml.py
Traceback (most recent call last):
  File "FixXml.py", line 7, in ?
  File "<string>", line 24, in parse
SyntaxError: not well-formed (invalid token): line 17, column 22

It's quite strange ! In fact, my test file is rather large, and I have the same
problem with all lines of the same kind, that look like:

  <SPAN class="font1">             </SPAN>

I tried to correct the file with Tidy, without any success, but when I remove
these lines, I can parse the file..

I don't understand !

I use Python 2.3 and the latest versions of cElemenTree and ElementTree , I have
the same result with both of them.

Thank you


More information about the XML-SIG mailing list