使用Spyder中的PIP在Python中安装某些库的问题

发布于 2025-02-04 11:56:53 字数 2021 浏览 1 评论 0原文

我一直在带有多个库的同一错误消息中,不是所有库,而是随机的。 我在这里和其他方程式板上可以找到的只是我需要升级我的pip,它已升级到最大值(22.1.2),但我仍然遇到相同的错误,没有添加的“警告:检查:检查PIP的最新版本。”

这就是我尝试安装Pyinstaller时得到的,

pip install pyinstaller
Collecting pyinstaller
  Using cached pyinstaller-5.1-py3-none-win_amd64.whl (1.2 MB)
Collecting pefile>=2017.8.1
  Using cached pefile-2022.5.30.tar.gz (72 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'done'
Requirement already satisfied: pywin32-ctypes>=0.2.0 in d:\program files\spyder\pkgs (from pyinstaller) (0.2.0)
Requirement already satisfied: setuptools in d:\program files\spyder\pkgs (from pyinstaller) (61.2.0)
Collecting altgraph
  Using cached altgraph-0.17.2-py2.py3-none-any.whl (21 kB)
Collecting pyinstaller-hooks-contrib>=2021.4
  Using cached pyinstaller_hooks_contrib-2022.6-py2.py3-none-any.whl (231 kB)
Collecting future
  Using cached future-0.18.2.tar.gz (829 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'error'
Note: you may need to restart the kernel to use updated packages.
  error: subprocess-exited-with-error
  
  python setup.py egg_info did not run successfully.
  exit code: 1
  
  [6 lines of output]
  Traceback (most recent call last):
    File "<string>", line 2, in <module>
    File "<pip-setuptools-caller>", line 34, in <module>
    File "C:\Users\tomer\AppData\Local\Temp\pip-install-01zbu624\future_a521b799a85941e08b0fd94b59c7d89a\setup.py", line 86, in <module>
      import src.future
  ModuleNotFoundError: No module named 'src'
  [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

Encountered error while generating package metadata.

See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
WARNING: There was an error checking the latest version of pip.

谢谢您的帮助

I’ve been running into the same error message with multiple libraries, not all libraries but randomly.
All I could find here and on other equation boards was that I need to upgrade my pip, it’s upgraded to the max (22.1.2) but I still get the same error, no with the added “WARNING: There was an error checking the latest version of pip.”

So this is what I get when I try to install pyinstaller

pip install pyinstaller
Collecting pyinstaller
  Using cached pyinstaller-5.1-py3-none-win_amd64.whl (1.2 MB)
Collecting pefile>=2017.8.1
  Using cached pefile-2022.5.30.tar.gz (72 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'done'
Requirement already satisfied: pywin32-ctypes>=0.2.0 in d:\program files\spyder\pkgs (from pyinstaller) (0.2.0)
Requirement already satisfied: setuptools in d:\program files\spyder\pkgs (from pyinstaller) (61.2.0)
Collecting altgraph
  Using cached altgraph-0.17.2-py2.py3-none-any.whl (21 kB)
Collecting pyinstaller-hooks-contrib>=2021.4
  Using cached pyinstaller_hooks_contrib-2022.6-py2.py3-none-any.whl (231 kB)
Collecting future
  Using cached future-0.18.2.tar.gz (829 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'error'
Note: you may need to restart the kernel to use updated packages.
  error: subprocess-exited-with-error
  
  python setup.py egg_info did not run successfully.
  exit code: 1
  
  [6 lines of output]
  Traceback (most recent call last):
    File "<string>", line 2, in <module>
    File "<pip-setuptools-caller>", line 34, in <module>
    File "C:\Users\tomer\AppData\Local\Temp\pip-install-01zbu624\future_a521b799a85941e08b0fd94b59c7d89a\setup.py", line 86, in <module>
      import src.future
  ModuleNotFoundError: No module named 'src'
  [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

Encountered error while generating package metadata.

See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
WARNING: There was an error checking the latest version of pip.

Thank you for your help

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文