Skip to content
This repository has been archived by the owner on Aug 11, 2021. It is now read-only.

Recent versions of html5lib have moved imports, breaking django-wysiwyg. #61

Open
mrmachine opened this issue Oct 7, 2016 · 1 comment

Comments

@mrmachine
Copy link

Since html5lib/html5lib-python#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
@vdboor
Copy link
Collaborator

vdboor commented Oct 26, 2016

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.

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

No branches or pull requests

2 participants