错误:无法为熊猫制造车轮,这是安装pyproject.toml的项目所必需的

发布于 2025-02-01 13:34:19 字数 2948 浏览 1 评论 0原文

我正在尝试通过pip安装pandas在我的笔记本电脑上安装熊猫。

环境:

  • 窗口11 Pro
  • Python 3.10.4
  • PIP版本22.0.4

兼容性:

C:\Users\PC>pip install pandas
WARNING: Ignoring invalid distribution -ywin32 (c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages)
WARNING: Ignoring invalid distribution -ywin32 (c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages)
Collecting pandas
  Using cached pandas-1.4.2.tar.gz (4.9 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: numpy>=1.21.0 in c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages (from pandas) (1.22.4)
Requirement already satisfied: python-dateutil>=2.8.1 in c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages (from pandas) (2.8.2)
Collecting pytz>=2020.1
  Using cached pytz-2022.1-py2.py3-none-any.whl (503 kB)
Requirement already satisfied: six>=1.5 in c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages (from python-dateutil>=2.8.1->pandas) (1.16.0)
Building wheels for collected packages: pandas
  Building wheel for pandas (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for pandas (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [2010 lines of output]
      C:\Users\PC\AppData\Local\Temp\pip-build-env-q3kdt5nb\overlay\Lib\site-packages\setuptools\config\setupcfg.py:459: SetuptoolsDeprecationWarning: The license_file parameter is deprecated, use license_files instead.
        warnings.warn(msg, warning_class)

...

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pandas
Failed to build pandas
ERROR: Could not build wheels for pandas, which is required to install pyproject.toml-based projects

我尝试过的内容:

  • 更新为22.1.1
  • 安装的车轮0.37.1
  • 未安装和安装的pip
  • 未安装和安装的Python 3.10.4

错误仍然可以使用


谢谢 @ akx < /a>已经指出,将来没有32位版本的熊猫。 参见有关github的讨论

I'm trying to install pandas via pip install pandas on my laptop.

Environment:

  • Window 11 Pro
  • Python 3.10.4
  • Pip version 22.0.4

Compatibility:

C:\Users\PC>pip install pandas
WARNING: Ignoring invalid distribution -ywin32 (c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages)
WARNING: Ignoring invalid distribution -ywin32 (c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages)
Collecting pandas
  Using cached pandas-1.4.2.tar.gz (4.9 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: numpy>=1.21.0 in c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages (from pandas) (1.22.4)
Requirement already satisfied: python-dateutil>=2.8.1 in c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages (from pandas) (2.8.2)
Collecting pytz>=2020.1
  Using cached pytz-2022.1-py2.py3-none-any.whl (503 kB)
Requirement already satisfied: six>=1.5 in c:\users\pc\appdata\local\programs\python\python310-32\lib\site-packages (from python-dateutil>=2.8.1->pandas) (1.16.0)
Building wheels for collected packages: pandas
  Building wheel for pandas (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for pandas (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [2010 lines of output]
      C:\Users\PC\AppData\Local\Temp\pip-build-env-q3kdt5nb\overlay\Lib\site-packages\setuptools\config\setupcfg.py:459: SetuptoolsDeprecationWarning: The license_file parameter is deprecated, use license_files instead.
        warnings.warn(msg, warning_class)

...

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pandas
Failed to build pandas
ERROR: Could not build wheels for pandas, which is required to install pyproject.toml-based projects

What I have tried:

  • updated pip to 22.1.1
  • installed wheel 0.37.1
  • uninstalled and installed pip
  • uninstalled and installed python 3.10.4

Error still reproducible with pandas 1.5.1


Thanks to @AKX which has pointed up that there is no and may will no 32-bit version of pandas in the future. See the discussion on GitHub.

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

夏の忆 2025-02-08 13:34:19

Pandas不需要Anaconda工作,而是基于输出中的Python310-32,您正在使用32位的Python构建。

pandas 显然 不为python运送32-乘式车轮3.10 python 3.8和python 3.9的Win32车轮)。 (可能有用于预制的32位轮子的替代来源 。。

您通过错误注意到了:元数据生成失效)。

如果您的系统能够运行64位Python,则应切换到它。

Pandas doesn't require Anaconda to work, but based on python310-32 in your output, you're using a 32-bit build of Python.

Pandas evidently does not ship 32-bit wheels for Python 3.10 (they do have win32 wheels for Python 3.8 and Python 3.9 though). (There could be alternate sources for pre-built 32-bit wheels, such as Gohlke's site.)

In other words, on that platform you would need to install Pandas from source, which will likely be a rather difficult undertaking, and can't be done directly within pip anyway (as you noticed via error: metadata-generation-failed).

If your system is capable of running 64-bit Python, you should switch to it.

没︽人懂的悲伤 2025-02-08 13:34:19

在Python 3.10中安装熊猫

python -m pip install pandas

Install pandas in Python 3.10

python -m pip install pandas
伴我心暖 2025-02-08 13:34:19

第一步

下载pandas wheel
选择适合您操作系统的一个

步骤,

安装轮子

pip install pandas-1.4.2-cp310-cp310-win32.whl

从绝对路径第三步

,您已成功安装了Pandas
检查一下

import pandas

Step one

Download pandas wheel,
Choose one that suits your operating system

Step two

install the wheel from absolute path

pip install pandas-1.4.2-cp310-cp310-win32.whl

Step three

You had successful installed pandas
Check it

import pandas
素食主义者 2025-02-08 13:34:19

我遇到的问题是Microsoft Visiual上的错误,请提及PANDA的轮子的错误,需要在使用PIP安装安装PANDAS之前的包装。现在,安装了Microsoft Visiual后,然后使用PIP Install panda,然后使用PIP安装转换,我没有错误。

the problem i had was error on microsoft visiual, mention befor the error of wheel of panda, needed the package of that before install pandas with pip install. now after install the microsoft visiual then use pip install panda and then pip install transform i had no errors.

烟火散人牵绊 2025-02-08 13:34:19

我通过将Python版本从3.10降低到3.9来解决问题。
也许您可以尝试一下!

I solved the problem by lowering the python version from 3.10 to 3.9.
Maybe you can have a try!

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文