On Aug 22, 5:56 pm, Justin Bronn <[EMAIL PROTECTED]> wrote:
> FYI, r8471 fixed my problems and all Oracle GeoDjango tests pass
> again.  Thanks.

That's good news, Justin--thanks for verifying!  (I have access to 9i
and 10g servers--not just XE--but spatial isn't licensed for any of
them so I had to cross my fingers.)

To follow up on the get_or_create failure, where the cx_Oracle driver
raises a more generic DatabaseError instead of an IntegrityError when
trying to INSERT a row lacking a required column value: Anthony
Tuininga, cx_Oracle's author, agreed that ORA-01400 should map to
IntegrityError and already commited that change to his trunk C code.
(Thanks, Anthony!)

So now we can fix the test case in theory by checking the backend and
driver version, and if it's 4.4.0 or earlier, we can continue to fail
with "Fail: this version of cx_Oracle incorrectly raises
DatabaseError" or the like.

However, I grep'ed the Django source and found two cases where we
catch IntegrityError specifically.  cx_Oracle probably misbehaves
there currently, but I'm not sure how common these code paths are and
what errors could result.

Currently, our docs say we require cx_Oracle version 4.2.1 or later.
It's not reasonable to expect Django users--especially ISPs and
corporations-- to upgrade to svn trunk and build the driver.  We could
ask Anthony to do a hurry-up 4.4.1 release with this fix in it, but
even so it's a lot to ask everyone to upgrade to a brand-new
driver version.  On the other hand, we're not talking about a large
number of Django/Oracle users currently, but that should change when
we have an official 1.0 release.

Opinions?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to