Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schemasync TypeError #29

Open
eileenzliu opened this issue Dec 4, 2013 · 4 comments
Open

Schemasync TypeError #29

eileenzliu opened this issue Dec 4, 2013 · 4 comments

Comments

@eileenzliu
Copy link

I got the following errors when trying to run schemasync on two databases:

Traceback (most recent call last):
File "/usr/local/bin/schemasync", line 9, in
load_entry_point('SchemaSync==0.9.2', 'console_scripts', 'schemasync')()
File "build/bdist.macosx-10.9-intel/egg/schemasync/schemasync.py", line 264, in main
File "build/bdist.macosx-10.9-intel/egg/schemasync/schemasync.py", line 123, in processor
File "build/bdist.macosx-10.9-intel/egg/schemasync/schemasync.py", line 210, in app
File "build/bdist.macosx-10.9-intel/egg/schemaobject/schema.py", line 48, in selected
File "build/bdist.macosx-10.9-intel/egg/schemaobject/schema.py", line 67, in databases
File "build/bdist.macosx-10.9-intel/egg/schemaobject/database.py", line 29, in DatabaseSchemaBuilder
File "build/bdist.macosx-10.9-intel/egg/schemaobject/connection.py", line 63, in execute
File "/Library/Python/2.7/site-packages/MySQL_python-1.2.4-py2.7-macosx-10.9-intel.egg/MySQLdb/cursors.py", line 187, in execute
query = query % tuple([db.literal(item) for item in args])
TypeError: not all arguments converted during string formatting

After I installed the schema sync, I had to run the following command to get rid of an error complaining "Mysqldb" not found.

sudo ln -s /usr/local/mysql/lib/libmysqlclient.18.dylib /usr/lib/libmysqlclient.18.dylib

Any clue what the problem is?

Thanks!

@ghost
Copy link

ghost commented Feb 26, 2014

Having the same problem, any updates on this?

@myzhan
Copy link

myzhan commented Apr 30, 2014

Yes, a change in MySQLdb 1.2.5 is not compatible with schemasync, use MySQLdb 1.2.4
farcepest/MySQLdb1@87d1145

@gpayet
Copy link

gpayet commented Dec 12, 2014

The issue is with schemaobject 0.5.3

Change line 32 of database.py from:

databases = conn.execute(sql, params)

to

 databases = conn.execute(sql, (params,))

conn.execute now expects an actual tuple in all cases.

@afilina
Copy link

afilina commented Mar 25, 2015

The package 1.2.4 is not available. I installed MySQLdb 1.2.3 using this:

sudo pip install -Iv http://sourceforge.net/projects/mysql-python/files/mysql-python/1.2.3/MySQL-python-1.2.3.tar.gz/download

My schemasync command worked fine after that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants