简体   繁体   English

由于未知原因,无法使用 pip 安装软件包

[英]Unable to install packages using pip for an unknown reason

I am new to coding, and am trying to install matplotlib to help with a school project.我是编码新手,正在尝试安装 matplotlib 以帮助完成学校项目。 I have installed packages using pip before, and I've never had any problem until now, when it says.我之前使用 pip 安装了软件包,直到现在我从来没有遇到过任何问题,当它说。 I'm sure it's blindingly obvious but as I said I'm very new.我敢肯定这非常明显,但正如我所说,我很新。 Thank you谢谢

C:\Users\kiran>pip install matplotlib
Traceback (most recent call last):
  File "C:\Users\kiran\AppData\Local\Programs\Python\Python37-32\Lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "C:\Users\kiran\AppData\Local\Programs\Python\Python37-32\Lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "D:\Users\kiran\AppData\Local\Programs\Python\Python37-32\Scripts\pip.exe\__main__.py", line 9, in <module>
TypeError: 'module' object is not callable

The error TypeError: 'module' object is not callable is an error message that occasionally occurs from a common typo of forgetting parens at the end of a method call or class instantiation.错误TypeError: 'module' object is not callable是一个错误消息,偶尔会出现在方法调用或 class 实例化结束时忘记括号的常见错字。 Ie IE

import MyClass
o = MyClass
#instead of 
o = MyClass()
# OR
var = o.MyMethod
# Instead of
var = o.MyMethod()

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM