We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I got some unusual HTML from an HTML email and it caused html2text to raise an exception.
html2text 2018.1.9 Python 3.5.2
>>> import html2text >>> test = '<i></i>‎' >>> html2text.html2text(test) Traceback (most recent call last): File "<console>", line 1, in <module> File "/var/www/example.com/venv-example/lib/python3.5/site-packages/html2text/__init__.py", line 937, in html2text return h.handle(html) File "/var/www/example.com/venv-example/lib/python3.5/site-packages/html2text/__init__.py", line 149, in handle self.feed(data) File "/var/www/example.com/venv-example/lib/python3.5/site-packages/html2text/__init__.py", line 146, in feed HTMLParser.HTMLParser.feed(self, data) File "/usr/lib/python3.5/html/parser.py", line 111, in feed self.goahead(0) File "/usr/lib/python3.5/html/parser.py", line 219, in goahead self.handle_entityref(name) File "/var/www/example.com/venv-example/lib/python3.5/site-packages/html2text/__init__.py", line 189, in handle_entityref self.handle_data(self.entityref(c), True) File "/var/www/example.com/venv-example/lib/python3.5/site-packages/html2text/__init__.py", line 802, in handle_data and re.match(r'[^\s.!?]', data[0]) IndexError: string index out of range
The text was updated successfully, but these errors were encountered:
Fix handling ‎ and ‏ marks
802fad1
- mid-text within stressed tags - right after stressed tags Fixes Alir3z4#201.
40a9c61
No branches or pull requests
I got some unusual HTML from an HTML email and it caused html2text to raise an exception.
html2text 2018.1.9
Python 3.5.2
The text was updated successfully, but these errors were encountered: