HTMLParseError for package 'xm.booking'

Bug #381432 reported by Sridhar Ratnakumar
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
PyPI Mirror
Fix Released
Medium
Daniel Kraft

Bug Description

A fix for this is available in my branch - http://bazaar.launchpad.net/~srid/+junk/pypi-mirror/revision/66 (also attaching as patch)

        2009-05-28 12:12:26,482 DEBUG Processing package xm.booking
 Traceback (most recent call last):
   File "parts/my-pypi-mirror/z3c.pypimirror/bin/pypimirror", line 14, in <module>
  z3c.pypimirror.mirror.run()
   File "/home/sridharr/as/pypm/parts/my-pypi-mirror/z3c.pypimirror/src/z3c/pypimirror/mirror.py", line 720, in run
  config["base_url"])
   File "/home/sridharr/as/pypm/parts/my-pypi-mirror/z3c.pypimirror/src/z3c/pypimirror/mirror.py", line 430, in mirror
  links = package.ls(filename_matches, external_links, follow_external_index_pages)
   File "/home/sridharr/as/pypm/parts/my-pypi-mirror/z3c.pypimirror/src/z3c/pypimirror/mirror.py", line 290, in ls
  return [(link[0], os.path.basename(link[0]), link[1]) for link in links]
   File "/home/sridharr/as/pypm/parts/my-pypi-mirror/z3c.pypimirror/src/z3c/pypimirror/mirror.py", line 258, in _links
  for link in self._fetch_links(remote_index_html):
   File "/home/sridharr/as/pypm/parts/my-pypi-mirror/z3c.pypimirror/src/z3c/pypimirror/mirror.py", line 170, in _fetch_links
  soup = BeautifulSoup(html)
   File "build/bdist.linux-i686/egg/BeautifulSoup.py", line 1499, in __init__
   File "build/bdist.linux-i686/egg/BeautifulSoup.py", line 1230, in __init__
   File "build/bdist.linux-i686/egg/BeautifulSoup.py", line 1263, in _feed
   File "/opt/ActivePython-2.6/lib/python2.6/HTMLParser.py", line 108, in feed
  self.goahead(0)
   File "/opt/ActivePython-2.6/lib/python2.6/HTMLParser.py", line 148, in goahead
  k = self.parse_starttag(i)
   File "/opt/ActivePython-2.6/lib/python2.6/HTMLParser.py", line 226, in parse_starttag
  endpos = self.check_for_whole_start_tag(i)
   File "/opt/ActivePython-2.6/lib/python2.6/HTMLParser.py", line 301, in check_for_whole_start_tag
  self.error("malformed start tag")
   File "/opt/ActivePython-2.6/lib/python2.6/HTMLParser.py", line 115, in error
  raise HTMLParseError(message, self.getpos())
 HTMLParser.HTMLParseError: malformed start tag, at line 22, column 11

Revision history for this message
Sridhar Ratnakumar (srid) wrote :
Revision history for this message
Daniel Kraft (dk-d9t) wrote :

Yep, that code was a bit too optimistic ;)
The patch is ok and I'll have to find out how to merge it correctly to my repo. Hints welcome. If I get it, I'll release a new version.

Changed in pypi-mirror:
assignee: nobody → Daniel Kraft (dk-d9t)
importance: Undecided → Medium
Revision history for this message
Sridhar Ratnakumar (srid) wrote :

Actually I was not sure as to how to 'fork' off from the project in launchpad (like one does in github, bitbucket, et. al..). So I ended up creating a *new* project.

Do I have the permission to fork the original pypi-mirror .. to enable seamless merging later?

Revision history for this message
Daniel Kraft (dk-d9t) wrote :

Merged in 1.0.14. Please check...

Changed in pypi-mirror:
status: New → Fix Released
Revision history for this message
Daniel Kraft (dk-d9t) wrote :

Meging is pretty easy with bzr, I just didn't find the correct URL. Now everything is good ;) I merged your code changes, but left the CHANGES.txt.

Revision history for this message
Daniel Kraft (dk-d9t) wrote :

Looks good with all my tests. Released.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.