TypeError: 'module' object is not callable error running pip install selenium

丶灬走出姿态 提交于 2020-06-17 11:21:27

问题


I have a fresh installation for Python on my PC. To reproduce the issue, I open the command prompt and executed the command:

pip install selenium

I am seeing the following error:

TypeError: 'module' object is not callable

error


回答1:


this fiexed it:

python -m pip install selenium --user




回答2:


This error message...

TypeError: 'module' object is not callable

...implies that the program was unable to locate pip.exe with in your system.

From the image it is pretty clear that Python is installed in D: drive while you were trying to access it from C: drive.

Factually, it doesn't matters where ever you install Python within your system as long as you know where it is at and preferably the path is in your system path. You can use the following command to locate the site packages e.g. pip install

import site
print(site.getsitepackages())

However, to keep things simple you need to install Python in it's default location and add the path to the system path. Then you can easily run:

pip install selenium


来源:https://stackoverflow.com/questions/59146236/typeerror-module-object-is-not-callable-error-running-pip-install-selenium

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!