wp231957 发表于 2023-2-13 14:27:46

请输入作者名 是什么鬼

>>> import wmi
请输入作者名:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "D:\Python37\lib\site-packages\wmi.py", line 99, in <module>
    import csv
File "D:\wpp\csv.py", line 5, in <module>
    data=csv.reader(f)
AttributeError: module 'csv' has no attribute 'reader'
>>>

isdkz 发表于 2023-2-13 14:32:57

你是不是安装错模块了?

(base) C:\Users\17139>pip show wmi
Name: WMI
Version: 1.5.1
Summary: Windows Management Instrumentation
Home-page: http://timgolden.me.uk/python/wmi.html
Author: Tim Golden
Author-email: mail@timgolden.me.uk
License: http://www.opensource.org/licenses/mit-license.php
Location: D:\secureworks\important\study\Program\python\Envs\base\Lib\site-packages
Requires: pywin32
Required-by:

wp231957 发表于 2023-2-13 14:40:28

isdkz 发表于 2023-2-13 14:32
你是不是安装错模块了?

D:\wpp>pip show wmi
Name: WMI
Version: 1.5.1
Summary: Windows Management Instrumentation
Home-page: http://timgolden.me.uk/python/wmi.html
Author: Tim Golden
Author-email: mail@timgolden.me.uk
License: http://www.opensource.org/licenses/mit-license.php
Location: d:\python37\lib\site-packages
Requires: pywin32
Required-by:

D:\wpp>

isdkz 发表于 2023-2-13 14:46:31

wp231957 发表于 2023-2-13 14:40
D:\wpp>pip show wmi
Name: WMI
Version: 1.5.1


会不会是你用的源被污染了?

wp231957 发表于 2023-2-13 14:54:23

isdkz 发表于 2023-2-13 14:46
会不会是你用的源被污染了?

不研究了,微软已经放弃wmic了   需要研究powershell了

isdkz 发表于 2023-2-13 14:57:49

wp231957 发表于 2023-2-13 14:54
不研究了,微软已经放弃wmic了   需要研究powershell了

好吧
页: [1]
查看完整版本: 请输入作者名 是什么鬼