[Zope] RE: ZMySQLDA product does not load

Norman Khine khine@btinternet.com
Thu, 19 Jul 2001 15:48:44 +0100


Like I said in my e-mail, you need to ensure you have python talking to
mysql. To do this, you will either have to install Distutils module from the
python site or better still update to python 2.1 -- as Zope 2.4 will be
moving to this, in which case Distutils is build with this.

Once this is done, install MySQL-python, ensuring you read the INSTALL.txt.

hth



-----Original Message-----
From: a_oki@yahoo.com [mailto:a_oki@yahoo.com]
Sent: Thursday, July 19, 2001 3:16 PM
To: Norman Khine
Subject: Re: ZMySQLDA product does not load


I just did and you where right, it returns an error

>>> import _mysql
Traceback (innermost last):
  File "<stdin>", line 1, in ?
ImportError: _mysql: init failed

Do you know of any work around? am new to Zope+python.


--- In zope@y..., "Norman Khine" <khine@b...> wrote:
> Hi,
> I have not used a win installation, but did you check if python can
talk to
> mysql?
> you can do his py startin python
> >>import _mysql
>
> If you get an error/traceback then this is the problem, you will
need to
> install MySQL-python correctly, it needs distutils as you are using
python
> 1.52. If you upgrade to python 2.1, then you would not need to
instal
> distutils as it comes with it.
>
> Also ensure that the setup.py file in MySQL-python points to your
mysql
> libraries.
>
> to check if MySQLDA connects to mysql, again from the python
prompt, try to
> import it.
>
> hth
>
> Norman
>
> =========================================
> "Eternity is Time
> Time, eternity
> To see the two as opposite
> Is Man's Perversity"
>
> The Book of Angelus Silesius
>
>
>
> -----Original Message-----
> From: zope-admin@z... [mailto:zope-admin@z...]On Behalf Of
> a_oki@y...
> Sent: Thursday, July 19, 2001 2:17 PM
> To: zope@z...
> Subject: [Zope] ZMySQLDA product does not load
>
>
> Hello,
>
> This is the files I am using for my build on Windows 2000
> Zope2.3.3
> MySQL 3.23.39
> Python 1.5.2
> ZMySQLDA-2.0.7
> MySQL-python 0.9.0
>
> ...and I get an error message on the DOS prompt, although Zope still
> starts but without the ZMySQLDA product (See end of file)
>
>
> Any help in tackling this so I can load the ZMySQLDA product would
be
> well appreciated.
>
> Amatare
>
>
>
> C:\Program Files\WebSite>"C:\Program
> Files\WebSite\bin\python.exe" "C:\Program F
> iles\WebSite\z2.py" -D
> ------
> 2001-07-19T12:54:39 ERROR(200) Zope Couldn't import
Products.ZMySQLDA
> Traceback (innermost last):
>   File C:\PROGRA~1\WEBSITE\lib\python\OFS\Application.py, line 528,
> in import_pr
> oducts
>     (Object: string)
>   File C:\Program
> Files\WebSite\lib\python\Products\ZMySQLDA\__init__.py, line 9
> 1, in ?
>   File C:\Program Files\WebSite\lib\python\Products\ZMySQLDA\DA.py,
> line 91, in
> ?
>   File C:\Program Files\WebSite\lib\python\Products\ZMySQLDA\db.py,
> line 89, in
> ?
> ImportError: _mysql: init failed
>
>
> ------
> 2001-07-19T12:54:46 INFO(0) ZServer HTTP server started at Thu Jul
19
> 13:54:46 2
> 001
>         Hostname: serendip
>         Port: 8080
> ------
> 2001-07-19T12:54:46 INFO(0) ZServer FTP server started at Thu Jul 19
> 13:54:46 20
> 01
>         Hostname: serendip
>         Port: 8021
> ------
> 2001-07-19T12:54:46 INFO(0) ZServer PCGI Server started at Thu Jul
19
> 13:54:46 2
> 001
>         Inet socket port: 8090
>
>
>
>
> _______________________________________________
> Zope maillist  -  Zope@z...
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )
>
>
>
> _______________________________________________
> Zope maillist  -  Zope@z...
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )