[issue26211] HTMLParser: “AssertionError: we should not get here!”

Yannick Duchêne report at bugs.python.org
Tue Jan 26 16:47:21 EST 2016


New submission from Yannick Duchêne:

Using HTMLParser on the attached file, I got this:

      File "/usr/lib/python3.5/html/parser.py", line 111, in feed
        self.goahead(0)
      File "/usr/lib/python3.5/html/parser.py", line 171, in goahead
        k = self.parse_starttag(i)
      File "/usr/lib/python3.5/html/parser.py", line 303, in parse_starttag
        endpos = self.check_for_whole_start_tag(i)
      File "/usr/lib/python3.5/html/parser.py", line 383, in check_for_whole_start_tag
        raise AssertionError("we should not get here!")
    AssertionError: we should not get here!

The file purposely contains an error, as I was to check the behaviour of my application in the case of this error … I finally triggered one in the library :-P

----------
components: Library (Lib)
files: sample.html
messages: 258975
nosy: Hibou57
priority: normal
severity: normal
status: open
title: HTMLParser: “AssertionError: we should not get here!”
versions: Python 3.5
Added file: http://bugs.python.org/file41721/sample.html

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26211>
_______________________________________


More information about the Python-bugs-list mailing list