1

I'm installing ZMYSQLDA for Z MYSQL Databae connection through buildout.

Here are my initial definitions:

parts=
     .....
     zmysqlda


[zmysqlda]
recipe = cns.recipe.zmysqlda
target = ${productdistros:location}

It seem ok, does build the instance and site works.

For information I have already installed MySQL_python throught exe file so I''m able to import MySQLdb.

When I introduce Products.ZMySQLDA in the eggs it tries to fetch MYSQL-python. I don't understand why since it's already installed.

Buidout log is

Unused options for buildout: 'eggs' 'download-directory'.
Updating productdistros.
Installing instance.
Getting distribution for 'MySQL-python==1.2.3'.
install_dir C:\Program Files\Plone 404/buildout-cache/eggs\tmparsmo9
error: The system cannot find the file specified
An error occured when trying to install MySQL-python 1.2.3. Look above this mess
age for any errors that were output by easy_install.
While:
  Installing instance.
  Getting distribution for 'MySQL-python==1.2.3'.
Error: Couldn't install: MySQL-python 1.2.3
*************** PICKED VERSIONS ****************
[versions]
collective.saconnect = 1.3
pas.plugins.sqlalchemy = 0.2
products.ploneboard = 2.2
products.ploneboardsubscription = 0.2
products.zmysqlda = 3.1.1
sqlalchemy = 0.6.6

#Required by:
#collective.saconnect 1.3
plone.app.z3cform = 0.5.3

#Required by:
#collective.saconnect 1.3
rwproperty = 1.0

#Required by:
#pas.plugins.sqlalchemy 0.2
z3c.saconfig = 0.12

#Required by:
#pas.plugins.sqlalchemy 0.2
zope.sqlalchemy = 0.6.1
Davi Lima
  • 800
  • 1
  • 6
  • 20
webbyfox
  • 1,049
  • 10
  • 22

1 Answers1

1

It's trying to install mysql-python because the one you've already installed is not on the buildout's PYTHONPATH.

I would start by removing the 'target=' option in the [zmysqlda] section. You really shouldn't be pointing anything at 'productdistros' these days. It may just be that buildout can't find zmysqlda's dependencies in 'target'. If that doesn't solve it, rerun the buildout with the -vv option and post the results here.

However, as long as you're using sqlalchemy anyway, why not use the SQLAlchemyDA which plays well with it...? Then you just need to add Products.SQLAlchemyDA (and the MySql db adapter - which I presume you have for sqlalchemy anyway) to the eggs list, and you don't need anything corresponding to the [zmysqlda] part.

Auspex
  • 2,175
  • 15
  • 35
  • Thanks very much. I can see now sql adapeter to connect MySQL. My intension to use SQLAlchemy to use MYSQL tables user to authenticate and role to decide the permission. Althought I have installed it I cant see any obvious way to add inside acl_user folder. I have installed pas.plugins.sqlalchemy 0.2 but cant see obvious place to configure with database table. – webbyfox Apr 06 '11 at 15:06
  • Post a separate question about pas.plugins.sqlalchemy - I'm working with the code at the moment, and should be able to help. – Auspex Apr 06 '11 at 16:20
  • It's here http://stackoverflow.com/questions/5569963/varchar-requires-a-length-when-rendered-on-mysql – webbyfox Apr 06 '11 at 16:44