我安装了Anaconda以简化许多python模块的管理。
之后我尝试了#34;导入子流程":
>>> import subprocess
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/sej/.config/anaconda3/lib/python3.6/subprocess.py", line 155, in <module>
_PopenSelector = selectors.SelectSelector
AttributeError: module 'selectors' has no attribute 'SelectSelector'
如何解决这个问题?
我试图使用matplotlib来解决这个问题。 尝试导入时,会出现此错误:
>>> import matplotlib
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/sej/.config/anaconda3/lib/python3.6/site-packages/matplotlib/__init__.py", line 127, in <module>
from matplotlib.compat import subprocess
File "/home/sej/.config/anaconda3/lib/python3.6/site-packages/matplotlib/compat/subprocess.py", line 27, in <module>
import subprocess
File "/home/sej/.config/anaconda3/lib/python3.6/subprocess.py", line 155, in <module>
_PopenSelector = selectors.SelectSelector
AttributeError: module 'selectors' has no attribute 'SelectSelector'