pyinstaller没有名为pyinstaller的模块 [英] pyinstaller No module named pyinstaller
问题描述
我在Mac osx sierra下安装了2个python版本: python 3.5 python 2.7
I have 2 python versions installed under my mac osx sierra: python 3.5 python 2.7
我使用以下命令在python3.5下安装了pyinstaller:
I installed pyinstaller under python3.5 with this command:
python3.5 -m pip install pyinstaller
如果我再次运行相同的命令,则会得到:
If I run again the same command I'm getting:
已满足要求:./lib/python3.5/site-packages中的pyinstaller 已经满足要求:./lib/python3.5/site-packages中的setuptools(来自pyinstaller)
Requirement already satisfied: pyinstaller in ./lib/python3.5/site-packages Requirement already satisfied: setuptools in ./lib/python3.5/site-packages (from pyinstaller)
对我来说,这意味着它已安装在python 3.5下并可供使用.
That to me means that is is installed under python 3.5 and ready to be used.
当我运行此命令时:
python3.5 -m pyinstaller mypython35script.py
我得到: /Library/Frameworks/Python.framework/Versions/3.5/bin/python3.5:没有名为pyinstaller的模块
I'm getting: /Library/Frameworks/Python.framework/Versions/3.5/bin/python3.5: No module named pyinstaller
为什么? 我在做什么错了?
why? What I'm doing wrong?
欢呼 D.
推荐答案
我在这里遇到了同样的问题,我尝试了所有方法,但最终我找到了解决方法:
I had same issue here, and i tried everything, but finally i found the solution :
我不得不将点数从19版降级到18.1:
I had to downgrade pip from version 19 to 18.1 :
pip install pip==18.1
然后安装PyInstaller:
Then install PyInstaller :
pip install pyinstaller
.
如您所见,我设法安装了它:
As you see i managed to install it : .
之后,您可以再次升级点数:
After that you can upgrade your pip again :
python -m pip install --upgrade pip
这篇关于pyinstaller没有名为pyinstaller的模块的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!