Can anyone tell me what error msg "line 1182 in parse" means when I'm trying to parse and xml in python
<p>This is the code that results in an error message:</p>

<pre><code>import urllib
import xml.etree.ElementTree as ET

url = raw_input('Enter URL:')

urlhandle = urllib.urlopen(url)

data = urlhandle.read()

tree = ET.parse(data)
</code></pre>

<p>The error:</p>

<p><img src="https://i.stack.imgur.com/eMKS2.png" alt="error msg screenshot"></p>

<p>I'm new to python. I did read documentation and a couple of tutorials, but clearly I still have done something wrong.  I don't believe it is the xml file itself because it does this to two different xml files.  </p>

<p>Consider using ElementTree's <a href="https://docs.python.org/2/library/xml.etree.elementtree.html#xml.etree.ElementTree.fromstring" rel="nofollow"><code>fromstring()</code></a>:</p>

<pre><code>import urllib
import xml.etree.ElementTree as ET

url = raw_input('Enter URL:')
# http://feeds.bbci.co.uk/news/rss.xml?edition=int

urlhandle = urllib.urlopen(url)    
data = urlhandle.read()

tree = ET.fromstring(data)

print ET.tostring(tree, encoding='utf8', method='xml')
</code></pre>

python xml parsing url elementtree