django-fluent / django-fluent-contents

A widget engine to display various content on Django pages
http://django-fluent.org/
Apache License 2.0
149 stars 39 forks source link

oembeditem installation issue #85

Closed sunjoomoon closed 7 years ago

sunjoomoon commented 7 years ago

Trying to install http://django-fluent-contents.readthedocs.io/en/latest/plugins/oembeditem.html, all seems fine. When I run migrate, then below is returned. Any tip as to what to look for?

Traceback (most recent call last):
  File "manage.py", line 10, in <module>
    execute_from_command_line(sys.argv)
  File "/srv/env/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 354, in execute_from_command_line
    utility.execute()
  File "/srv/env/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 328, in execute
    django.setup()
  File "/srv/env/local/lib/python2.7/site-packages/django/__init__.py", line 18, in setup
    apps.populate(settings.INSTALLED_APPS)
  File "/srv/env/local/lib/python2.7/site-packages/django/apps/registry.py", line 85, in populate
    app_config = AppConfig.create(entry)
  File "/srv/env/local/lib/python2.7/site-packages/django/apps/config.py", line 86, in create
    module = import_module(entry)
  File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
    __import__(name)
  File "/srv/env/local/lib/python2.7/site-packages/fluent_contents/plugins/oembeditem/__init__.py", line 5, in <module>
    import micawber
  File "/srv/env/local/lib/python2.7/site-packages/micawber/__init__.py", line 5, in <module>
    from micawber.parsers import extract
  File "/srv/env/local/lib/python2.7/site-packages/micawber/parsers.py", line 13, in <module>
    from bs4 import BeautifulSoup
  File "/srv/env/local/lib/python2.7/site-packages/bs4/__init__.py", line 30, in <module>
    from .builder import builder_registry, ParserRejectedMarkup
  File "/srv/env/local/lib/python2.7/site-packages/bs4/builder/__init__.py", line 314, in <module>
    from . import _html5lib
  File "/srv/env/local/lib/python2.7/site-packages/bs4/builder/_html5lib.py", line 70, in <module>
    class TreeBuilderForHtml5lib(html5lib.treebuilders._base.TreeBuilder):
AttributeError: 'module' object has no attribute '_base'
sunjoomoon commented 7 years ago

Here is how it could be solved. After googling around, I found the issue was version conflicts. See this http://stackoverflow.com/questions/38447738/beautifulsoup-html5lib-module-object-has-no-attribute-base

Just update below,

pip install --upgrade beautifulsoup4
pip install --upgrade html5lib

Thanks to http://stackoverflow.com/users/3583676/user50500