Re: [SQLObject] Database exceptions handling

2006-10-05 Thread Oleg Broytmann
Hello! On Wed, Jul 26, 2006 at 08:03:16AM +0300, Mircea Amarascu wrote: > I've attached the patch Applied and committed in the revision 1981 in the trunk. It caused a minor problem in test_indexes.py in the code except (mod.ProgrammingError, mod.IntegrityError, mod.OperationalError, mod.

Re: [SQLObject] Database exceptions handling

2006-08-15 Thread Oleg Broytmann
Hello, On Tue, Aug 15, 2006 at 12:38:27PM +0300, Mircea Amarascu wrote: > Regarding the unified database exception handling we've started to > implement for > the MySQL and SQLite engines, I have a couple of questions: > > 1. Do you consider implementing this approach, or are you raher waiting f

Re: [SQLObject] Database exceptions handling

2006-08-15 Thread Mircea Amarascu
Oleg Broytmann wrote: >Can you also add some tests? For example, add a duplicate record (key), > catch an exception and test that the exception is really... what should it > be? IntegrityError? ProgrammingError? >SQLObject's tests (based on py.test framework) allow one to limit > platforms

Re: [SQLObject] Database exceptions handling

2006-07-31 Thread Oleg Broytmann
On Mon, Jul 31, 2006 at 11:32:21AM +0300, Mircea Amarascu wrote: > However, I found it useful to mark such an event in SQLObject with a > specific exception, > dberrors.DuplicateEntryError This is exactly the point! I'd like to have a broader (comparing to DB API 2.0) set of exceptions. Implem

Re: [SQLObject] Database exceptions handling

2006-07-31 Thread Mircea Amarascu
Oleg Broytmann wrote: >Can you also add some tests? For example, add a duplicate record (key), > catch an exception and test that the exception is really... what should it > be? IntegrityError? ProgrammingError? > A duplicate entry record will be signaled in both MySQL and SQLite modules as

Re: [SQLObject] Database exceptions handling

2006-07-31 Thread Dan Pascu
On Sunday 30 July 2006 13:58, Oleg Broytmann wrote: > On Wed, Jul 26, 2006 at 08:03:16AM +0300, Mircea Amarascu wrote: > > I've read the "Handling exceptions" topic on this mailing list > > (http://www.mail-archive.com/sqlobject-discuss%40lists.sourceforge.ne > >t/msg00975.html) and decided to take

Re: [SQLObject] Database exceptions handling

2006-07-30 Thread Oleg Broytmann
On Wed, Jul 26, 2006 at 08:03:16AM +0300, Mircea Amarascu wrote: > I've read the "Handling exceptions" topic on this mailing list > (http://www.mail-archive.com/sqlobject-discuss%40lists.sourceforge.net/msg00975.html) > and decided to take a step further and try to add a database exception > hiera

[SQLObject] Database exceptions handling

2006-07-29 Thread Mircea Amarascu
Hello, I've read the "Handling exceptions" topic on this mailing list (http://www.mail-archive.com/sqlobject-discuss%40lists.sourceforge.net/msg00975.html) and decided to take a step further and try to add a database exception hierarchy to SQLObject, as described in PEP249 (http://www.python.

[SQLObject] Database exceptions handling

2006-07-28 Thread Mircea Amarascu
Hello, I've read the "Handling exceptions" topic on this mailing list (http://www.mail-archive.com/sqlobject-discuss%40lists.sourceforge.net/msg00975.html) and decided to take a step further and try to add a database exception hierarchy to SQLObject, as described in PEP249 (http://www.python.or