小编Son*_*hao的帖子

ImportError:无法导入名称'HTMLAwareEntitySubstitution'

我刚刚设置了beautifulsoup4-4.1.0并将pip升级到版本9.0.1.当我这样写:

from bs4 import BeautifulSoup
Run Code Online (Sandbox Code Playgroud)

发生错误:

Traceback (most recent call last):
  File "<pyshell#4>", line 1, in <module>
    from bs4 import BeautifulSoup
  File "D:\Program Files (x86)\Python35-32\lib\site-packages\bs4\__init__.py", line 35, in <module>
    from .builder import builder_registry, ParserRejectedMarkup
  File "D:\Program Files (x86)\Python35-32\lib\site-packages\bs4\builder\__init__.py", line 7, in <module>
    from bs4.element import (
ImportError: cannot import name 'HTMLAwareEntitySubstitution'
Run Code Online (Sandbox Code Playgroud)

我该怎么办?非常感谢.

beautifulsoup python-3.5

7
推荐指数
1
解决办法
4656
查看次数

标签 统计

beautifulsoup ×1

python-3.5 ×1