我知道这个问题在这个网站上被问了很多,但我已经尝试了所有给出的解决方案,但我不知道如何解决这个问题。
对于初学者:我在Windows 10使用Python 3.6. 我安装Anaconda 为我的 IDE。
我尝试BeautifulSoup4使用pipinstall 安装beautifulsoup4,但我得到了
已满足要求
回复。
我试图运行的代码只是
from bs4 import BeautifulSoup4
to which I get the error: ImportError: cannot import name 'BeautifulSoup4'
The full error is:
runfile('C:/Users/ter/.spyder-py3/untitled1.py', wdir='C:/Users/ter/.spyder-py3')
Traceback (most recent call last):
File "<ipython-input-21-8717178e85e1>", line 1, in <module>
runfile('C:/Users/ter/.spyder-py3/untitled1.py', wdir='C:/Users/ter/.spyder-py3')
File "C:\Users\ter\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py", line 705, in runfile
execfile(filename, namespace)
File "C:\Users\ter\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py", line 102, in execfile
exec(compile(f.read(), filename, 'exec'), namespace)
File "C:/Users/ter/.spyder-py3/untitled1.py", line 8, in …Run Code Online (Sandbox Code Playgroud)