django-wysiwyg
django-wysiwyg copied to clipboard
Recent versions of html5lib have moved imports, breaking django-wysiwyg.
Since https://github.com/html5lib/html5lib-python/pull/110 was merged, we get:
Traceback (most recent call last):
File "/opt/django-icekit/icekit/plugins/text/tests.py", line 35, in test_sanitize_html5lib
sanitized = sanitize_html(self.HTML1_ORIGINAL)
File "/usr/local/lib/python2.7/dist-packages/django_wysiwyg/utils.py", line 41, in sanitize_html5lib
from html5lib import treebuilders, treewalkers, serializer, sanitizer
ImportError: cannot import name sanitizer
I've solved a similar issue here: https://github.com/django-fluent/django-fluent-contents/blob/master/fluent_contents/utils/html.py This could be useful to create a pull request, it supports both the old and new style.