Plone ZMySQLDA,无法使用buildout安装MySQL-python 1.2.4c1

时间:2012-11-08 11:53:04

标签: plone buildout ploneformgen

我想使用mysql表单ploneformgen,但是我 无法扩建plone。

buildout log http://pastie.org/5345272.js

Getting required 'MySQL-python>=1.2.1'
  required by Products.ZMySQLDA 3.1.1.
We have no distributions for MySQL-python that satisfies 'MySQL-python>=1.2.1'.
Getting distribution for 'MySQL-python>=1.2.1'.
Running easy_install:
/usr/local/Plone/Python-2.6/bin/python "-c" "from setuptools.command.easy_install import main; main()" "-mUNxd" "/usr/local/Plone/zeocluster/../buildout-cache/eggs/tmpDSODu0" "-Z" "/usr/local/Plone/buildout-cache/downloads/dist/MySQL-python-1.2.4c1.zip"
path=/usr/local/Plone/buildout-cache/eggs/distribute-0.6.21-py2.6.egg

Processing MySQL-python-1.2.4c1.zip
Running MySQL-python-1.2.4c1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-gFbWLf/MySQL-python-1.2.4c1/egg-dist-tmp-16g1TE
The required version of distribute (>=0.6.28) is not available,
and can't be installed while this script is running. Please
install a more recent version first, using
'easy_install -U distribute'.

(Currently using distribute 0.6.19 (/usr/local/Plone/Python-2.6/lib/python2.6/site-packages/distribute-0.6.19-py2.6.egg))
error: Setup script exited with 2
An error occured when trying to install MySQL-python 1.2.4c1. Look above this message for any errors that were output by easy_install.
While:
  Installing client1.
  Getting distribution for 'MySQL-python>=1.2.1'.
Error: Couldn't install: MySQL-python 1.2.4c1
*************** PICKED VERSIONS ****************
[versions]
Products.PloneFormGen = 1.7.1
Products.ZMySQLDA = 3.1.1
collective.classifieds = 1.6
plone.app.ldap = 1.2.8
quintagroup.dropdownmenu = 1.2.5
quintagroup.pfg.captcha = 1.0.5
zettwerk.ui = 1.1.1

buildout conf http://pastie.org/5345300

一些链接:

http://blog.mysqlboy.com/2010/08/installing-mysqldb-python-module.html

http://plone.293351.n2.nabble.com/Plone-amp-MySQL-No-quot-Z-MYSQL-Database-Connection-quot-from-ZMI-td5487160.html

2 个答案:

答案 0 :(得分:2)

看来MySQLdb egg需要更新版本的distribute

The required version of distribute (>=0.6.28) is not available,

(Currently using distribute 0.6.19 (/usr/local/Plone/Python-2.6/lib/python2.6/site-packages/distribute-0.6.19-py2.6.egg))

首先升级你的distribute蛋;例如,如果您使用统一安装程序,则versions.cfg会固定版本。如果是,请修改versions.cfg以更正其中的版本号:

[versions]
...
# Buildout infrastructure
...
distribute = 0.6.28

答案 1 :(得分:1)

虽然您对特定问题有一个非常好的答案,但我强烈建议忘记ZMySQLDA并使用SQLAlchemyDA,它允许您访问SQLAlchemy支持的任何数据库(我使用了所有的MySQL,PostGreSQL,Oracle,SQLServer)单个产品,并得到更好的支持。