beautifulsoup, html5lib: module object has no attribute _base

Ehvince picture Ehvince · Jul 19, 2016 · Viewed 36.1k times · Source

When I updated my packages I have this new error:

class TreeBuilderForHtml5lib(html5lib.treebuilders._base.TreeBuilder):
AttributeError: 'module' object has no attribute '_base'

I tried to update beautifulsoup, with no more result. How can I fix that?

Answer

Modriano picture Modriano · Aug 6, 2016

I upgraded beautifulsoup4 and html5lib and it resolved the issue.

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