2017-06-06 55 views
-7

ModuleNotFoundError:沒有名爲 '硒' 模塊無模塊名爲 '硒'

the python version selenium PIP安裝硒,它讓我想起了下面: Requirement already satisfied: selenium in d:\program files\python\lib\site-packages

和目錄「d:\ Program Files文件\ python'是python 3.6

似乎每件事都是賴特。 win7,python3.6並把它放在path中,selenium3.4和它的wright位置,pip9.0與python3.6。

我不知道我錯了。

英語不是我的母語,我不擅長它,我試着給予更多的信息和細節。

+0

你安裝了它嗎? – IsaacDj

+0

selenum?pip install selenium –

回答

1

它看起來像你可能運行在不同版本的python,然後你的點是安裝。您可以使用pip --version進行檢查。例如:

我可以檢查我的3.5蟒蛇分支

pip --version pip 9.0.1 from /Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages (python 3.5) and from here pip freeze will list the modules installed under the python3 branch...

...對,如果我檢查2.7分支:

pip2 --version pip 9.0.1 from /Library/Python/2.7/site-packages (python 2.7) I will find a different set of packages installed using pip2 freeze.

如果你一個分支下安裝硒是在另一個分支下運行你的代碼,這會導致你的神祕錯誤。如果您需要更多幫助,請回複評論。希望這可以幫助!

+0

pip 9.0.1來自D:\ Program Files \ python \ lib \ site-packages \ pip-9.0.1-py3.6.egg(p thon 3.6) –

+0

python3.6,pip9。 0.1,我認爲他們是wright.and我使用python3.6。 –

+0

如果你用python 3.6打開交互式窗口,你可以在那裏導入硒? – RandallShanePhD