Re: Backend-specific lookups

2014-11-16 Thread Anssi Kääriäinen
A possible solution is to just register a custom as_vendor method in the backend's initialization code. You could also alter Oracle's compiler.compile() method to check for backend specific implementation class, and use that instead of the original one. Something like: backend_lookup_overrides =

Re: Request for removal: Mysql warnings get promoted to Exceptions in debug mode

2014-11-16 Thread Karen Tracey
Hmm, looking at the code that existed before the filterwarnings promotion to error, the older code was catching Database.Warning exceptions and re-raising them with the warning information included. This was before my time but it seems the older code was simply making the exceptions raised for DB w

Re: Request for removal: Mysql warnings get promoted to Exceptions in debug mode

2014-11-16 Thread Chi Ho Kwok
This is working as intended; on most databases, inserting a 11 character text value into a VARCHAR(10) raises an error. On MySQL, depending on if strict mode is enabled*, it either inserts "just fine" by truncating "12345678901" to "1234567890" with a warning, or fails with an error. As silent

Re: Backend-specific lookups

2014-11-16 Thread Marc Tamlyn
The test failures on the CI would suggest that overriding `get_db_prep_lookup` is a problem! There are changes on my ranges branch which move the % sign addition out of `Field.get_db_prep_lookup` and into the relevant lookup. This makes overriding certain lookups (e.g. contains, startswith etc) mu

Fellow Report: Week 3

2014-11-16 Thread Berker Peksağ
Hi all, Here is this week's report. You can see a more readable version of this report at https://code.djangoproject.com/wiki/DjangoFellows/BerkerPeksag#Weekof2014-11-10 Pull requests - Authored ^ * [Committed] https://github.com/django/django/pull/3495 -- Fixed #22407

Re: Backend-specific lookups

2014-11-16 Thread Shai Berger
On Sunday 16 November 2014 00:46:43 Josh Smeaton wrote: > Clever. I don't mind this approach at all. Will the overriding of > get_db_prep_lookup interfere with other implementations though? > Yes, it probably would. It is there because the default one for the lookup adds % signs around the value

Re: Multiple template engines for Django - week 5

2014-11-16 Thread Aymeric Augustin
Hello, Here’s my sixth update: https://myks.org/en/multiple-template-engines-for-django/#2014-11-16 I have a first pull request ready for review: https://github.com/django/django/pull/3555 Whenever possible, I’ll merge changes that make sense regardless of the Multiple Template Engines Project

Re: Multiple template engines for Django - week 1

2014-11-16 Thread Aymeric Augustin
> On 4 nov. 2014, at 21:38, Aymeric Augustin > wrote: > > 2014-11-04 20:58 GMT+01:00 Preston Timmons >: > With the new template update, do you foresee > django.utils.setup_test_template_loader and > django.utils.restore_template_loaders still working? > > If