MySQL Forums
Forum List  »  Connector/Python

Re: Problems in building 1.2.2 on Mac OS 10.5
Posted by: Eva Heinz
Date: November 24, 2008 04:24AM

Hej everyone,

I worked on this for a week now and have no clue what to do anymore.

I finally got the Python MySQL 1.2.2 installed following a lot of helpful comments on the internet; I also work on Mac OS 10.5.

When trying 'import MySQLdb' in python, however, I get the following error:Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "MySQLdb/__init__.py", line 19, in <module>
import _mysql
File "build/bdist.macosx-10.5-i386/egg/_mysql.py", line 7, in <module>
File "build/bdist.macosx-10.5-i386/egg/_mysql.py", line 6, in __bootstrap__
ImportError: dynamic module does not define init function (init_mysql)

So, following several people's advice, I changed my MySQL to a 32-bit-version. Hm. Still does not work. So I de- and reinstalled the 1.2.2. Got it installed again, but the error message in python remains (almost) the same:

>>> import MySQLdb
/Library/Python/2.5/site-packages/MySQL_python-1.2.2-py2.5-macosx-10.5-i386.egg/_mysql.py:3: UserWarning: Module _mysql was already imported from /Library/Python/2.5/site-packages/MySQL_python-1.2.2-py2.5-macosx-10.5-i386.egg/_mysql.pyc, but /Users/eva/MySQL-python-1.2.2 is being added to sys.path
import sys, pkg_resources, imp
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "MySQLdb/__init__.py", line 19, in <module>
import _mysql
File "build/bdist.macosx-10.5-i386/egg/_mysql.py", line 7, in <module>
File "build/bdist.macosx-10.5-i386/egg/_mysql.py", line 6, in __bootstrap__
ImportError: dynamic module does not define init function (init_mysql)

anybody got any idea??? I just started working with Unix this summer and am entirely lost now :-(

many thanks,

Eva

Options: ReplyQuote


Subject
Written By
Posted
Re: Problems in building 1.2.2 on Mac OS 10.5
November 24, 2008 04:24AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.