Tim Littlemore wrote:


Kevin Dangoor wrote:

I believe that IntegrityError comes from your database driver. You'll
likely have to import it from there.

Kevin

Thanks Kevin,

That was it! Fixed it by adding this to controllers.py:

from _mysql_exceptions import *



Cheers,

Tim

I asked Ian about this some time back and you can do it more generically like this:

MyClass._connection.module.IntegrityError

This was about 3 months back and I haven't tried it since then.

- jmj

Reply via email to