[英]While installing pyinstaller, this occured : ERROR: Could not install packages due to an OSError: [WinError 2]
When I try to install pyinstaller
in windows machine through pip
gives me the following error.当我尝试通过pip
在 windows 机器上安装pyinstaller
时,出现以下错误。
What I tried:我尝试了什么:
pip install pyinstaller
Error:错误:
Installing collected packages: pyinstaller
WARNING: Failed to write executable - trying to use .deleteme logic
ERROR: Could not install packages due to an OSError: [WinError 2] The
system cannot find the file specified: 'C:\\...\\Python310\\Scripts\\pyi-archive_viewer.exe' ->
'C:\\...\\Python310\\Scripts\\pyi-archive_viewer.exe.deleteme'
I had a similar problem " Requirement already satisfied " with the Pillow module.我对 Pillow 模块有类似的问题“要求已经满足”。 I saw it in IDE, but it was broken.我在 IDE 看到它,但它坏了。 So I deleted the package folder in C:\Python310\Lib\site-packages
and reinstalled it.所以我删除了C:\Python310\Lib\site-packages
中的 package 文件夹并重新安装。 You could try to do the same.你可以尝试做同样的事情。
I had the same issue.我遇到过同样的问题。 I solved it by uninstallation of partially installed pyinstaller.我通过卸载部分安装的 pyinstaller 解决了这个问题。 Then I installed it as Administrator.然后我以管理员身份安装它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.