Oleg and everyone else...
I'm not accusing anyone of anything. :)
I totally appreciate all the hard work you've done.
The documentation below is just a link I provided. I am not the author, nor am I maintainer of the documentation. So I can't correct it.
Thank you for the explanation!
On Mon, Oct 20, 2008 at 12:54:22AM -0700, Sam's Lists wrote:The accusation "SqlObject does not catch and re-throw the exceptions of
> A few weeks ago I came across a problem catching Integrity Error.
> Unfortunately it took me a while to find the workaround.
the underlying DB-API module." is simply not true. It was changed long ago.
SQLObject catches MySQdb.IntegrityError and rethrows it as
> Can we just export IntegrityError properly?
dberrors.IntegrityError in mysqconnection.py. If it is not enough - please
elaborate. If it's enough - please delete or update the first accusation on
PS. Please also update the second accusation. It is true that SQLObject
somewhat messes a few different namespaces but it has mechanisms to help
the user in this area. First, for most attributes you cannot create
a column if there is an attribute or function with the same name:
expire = StringCol()
Traceback (most recent call last):
File "./test1.py", line 14, in <module>
line 92, in __new__
line 784, in __classinit__
line 334, in addColumn
% (soClass.__module__, soClass.__name__, name, name))
AssertionError: The class __main__.Test already has a variable or method
'expire', you cannot add the column 'expire'
'dirty' seems to be a rare exception - it is set long after the name
clash check. I will add the issue to my TODO.
Second, SQLObject allows to have two different names for a column
- python name and database name:
_expire = StringCol(dbName="expire")
1/QueryR : CREATE TABLE test (
id INTEGER PRIMARY KEY,
Oleg Broytmann http://phd.pp.ru/ firstname.lastname@example.org
Programmers don't die, they just GOSUB without RETURN.
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
sqlobject-discuss mailing list