Xml parsing with python -


I am using xml with Python xmltodict . But I'm getting the following error,

  xml.parsers.expat.ExpatError: mismatched tag: line 2890, column2  

this is my code,

  import xmltodict import urllib2 url = "url here" data = xmltodict.parse (urllib2.urlopen (url) .read () print data   

I have tried to use the Entry

here, with the at print, the print code 'urlib2 import lxml.etree',

  Url = "Url here" xmldata = urllib2.urlopen (url) .read () root = ET.frost string (xmldata) print 'full' print route  

This also helps me Error,

  lxml.etree.XMLSyntaxError: Opening and closing tag mismatch: Client ID line 54 and type, line 55, column 14  

I know that there is a problem in XML
My question is, what is the way to read all the nodes except that it is xml ?


Comments