Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Found a bug in version 1.1: "AssertionError: <EMPTY MESSAGE>" caused by html5parser parsing failure. #557

Open
aT0ngMu opened this issue Feb 20, 2023 · 0 comments

Comments

@aT0ngMu
Copy link

aT0ngMu commented Feb 20, 2023

Hi,I Found a bug in version 1.1: "AssertionError: " caused by html5parser parsing failure.The following is the crash stack information:

[1676863707] === Uncaught Python exception: ===
[1676863707] AssertionError: <EMPTY MESSAGE>
[1676863707] Traceback (most recent call last):
[1676863707] File "/home/server1/adashwy/DriverCollections/exp_drivers/pyfuzzgen_drivers/bs4/beautifulsoup_driver/beautifulsoup_driver.py", line 40, in TestOneInput
[1676863707] instance = BeautifulSoup(remaining_data, features=parsers[idx])
[1676863707] File "/home/server1/.local/lib/python3.8/site-packages/bs4/init.py", line 333, in init
[1676863707] self._feed()
[1676863707] File "/home/server1/.local/lib/python3.8/site-packages/bs4/init.py", line 452, in _feed
[1676863707] self.builder.feed(self.markup)
[1676863707] File "/home/server1/.local/lib/python3.8/site-packages/bs4/builder/_html5lib.py", line 99, in feed
[1676863707] doc = parser.parse(markup, **extra_kwargs)
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 284, in parse
[1676863707] self._parse(stream, False, None, *args, **kwargs)
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 133, in _parse
[1676863707] self.mainLoop()
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 242, in mainLoop
[1676863707] new_token = phase.processEndTag(new_token)
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 2534, in processEndTag
[1676863707] new_token = self.parser.phase.processEndTag(token)
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 496, in processEndTag
[1676863707] return func(token)
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 2089, in endTagTable
[1676863707] self.clearStackToTableBodyContext()
[1676863707] File "/usr/local/lib/python3.8/dist-packages/html5lib/html5parser.py", line 2036, in clearStackToTableBodyContext
[1676863707] assert self.parser.innerHTML
[1676863707] AssertionError: <EMPTY MESSAGE>

The following is the testcase that triggers the crash.
testcase.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant