gpt4 book ai didi

python - 无法安装 MySQL-python "invalid command ' egg_info'”

转载 作者:太空宇宙 更新时间:2023-11-03 12:23:01 26 4
gpt4 key购买 nike

运行后出现奇怪的错误 $ pip 安装 mysql-python

有没有人见过这样的“egg_info”无效的错误?

我正在运行 OSX mountain lion

Downloading/unpacking MySQL-python
Using download cache from /Users/Marcus/.pip/cache/https%3A%2F%2Fpypi.python.org%2Fpackages%2Fsource%2FM%2FMySQL-python%2FMySQL-python-1.2.4.zip
Running setup.py egg_info for package MySQL-python
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.28.tar.gz
Extracting in /var/folders/ss/nxvs3w690xqbpvr_l0v31mrw0000gn/T/tmpg_MvY6
Now working in /var/folders/ss/nxvs3w690xqbpvr_l0v31mrw0000gn/T/tmpg_MvY6/distribute-0.6.28
Building a Distribute egg in /Users/Marcus/sites/venv/build/MySQL-python
/Users/Marcus/sites/venv/build/MySQL-python/distribute-0.6.28-py2.7.egg
usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: -c --help [cmd1 cmd2 ...]
or: -c --help-commands
or: -c cmd --help

error: invalid command 'egg_info'
Complete output from command python setup.py egg_info:
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.28.tar.gz

Extracting in /var/folders/ss/nxvs3w690xqbpvr_l0v31mrw0000gn/T/tmpg_MvY6

Now working in /var/folders/ss/nxvs3w690xqbpvr_l0v31mrw0000gn/T/tmpg_MvY6/distribute-0.6.28

Building a Distribute egg in /Users/Marcus/sites/venv/build/MySQL-python

/Users/Marcus/sites/venv/build/MySQL-python/distribute-0.6.28-py2.7.egg

usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]

or: -c --help [cmd1 cmd2 ...]

or: -c --help-commands

or: -c cmd --help



error: invalid command 'egg_info'

----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /Users/Marcus/sites/venv/build/MySQL-python
Storing complete log in /Users/Marcus/.pip/pip.log

谢谢

--- 我在运行时遇到同样的错误 $ pip 安装 django

最佳答案

您需要分发包,它现在位于 setuptools 中:

pip install --upgrade setuptools

关于python - 无法安装 MySQL-python "invalid command ' egg_info'”,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18941261/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com