Re: [Django] #25687: Document how backends should monkey patch expressions

2016-02-17 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  closed
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:  fixed
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Tim Graham ):

 In [changeset:"477b82cf8a7eefac98ff4f5afb4754727f4b0004" 477b82cf]:
 {{{
 #!CommitTicketReference repository=""
 revision="477b82cf8a7eefac98ff4f5afb4754727f4b0004"
 [1.9.x] Fixed #25687 -- Documented how to add database function support to
 third-party backends.

 Thanks Kristof Claes for the initial patch.

 Backport of 88034c9938d92193d2104ecfe77999c69301dcc1 from master
 }}}

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.58dc7ca2d86fd4bcffe6695e8a6ce5af%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2016-02-17 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  closed
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:  fixed
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Tim Graham ):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"88034c9938d92193d2104ecfe77999c69301dcc1" 88034c99]:
 {{{
 #!CommitTicketReference repository=""
 revision="88034c9938d92193d2104ecfe77999c69301dcc1"
 Fixed #25687 -- Documented how to add database function support to third-
 party backends.

 Thanks Kristof Claes for the initial patch.
 }}}

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.d8f123a7a5f8cd61d7f00366ce08c155%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2016-02-12 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by timgraham):

 * needs_better_patch:  1 => 0


Comment:

 [https://github.com/django/django/pull/6136 Updated PR]

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.dbf1efe8dd438cc853c64bb9b40a68a6%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2016-02-11 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by timgraham):

 * easy:  1 => 0


--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.7aed112852a41083705ae17c3172ca85%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-09 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  1|UI/UX:  0
-+-
Changes (by timgraham):

 * needs_better_patch:  0 => 1
 * stage:  Ready for checkin => Accepted


Comment:

 Left some comments for improvement. Please uncheck "Patch needs
 improvement" when you update the pull request.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.a876446de532c0b3e7ed752357216b5a%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-
Changes (by carljm):

 * stage:  Accepted => Ready for checkin


Comment:

 Force-pushing on every change is fine for a smaller patch like this. Patch
 looks good to me, thanks for the contribution, and congratulations,
 welcome to the team :-)

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.8936872f967507f0028ca51e300ca118%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-

Comment (by kristofclaes):

 I have updated my PR again so it uses `template` again and passes it to
 `as_sql`.

 I've been force pushing these changes. If I'm not using the correct
 workflow here, please let me know. This is my first contribution to OSS
 ever.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.49507d0f337c7b9eba4da161bb66c506%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-

Comment (by carljm):

 After discussion with jarshwah and manfre, we've agreed that none of us
 really care that much between simple monkeypatching vs a public API that
 does the monkeypatching internally. I don't think there's any practical
 benefit to the public API, even in terms of future flexibility: either way
 we're committed to the `as_vendor` method system, whether the method gets
 there via monkeypatching or otherwise is irrelevant. The only real benefit
 is that recommending monkeypatching in our documentation looks bad :-)

 I think this doc patch should go ahead as-is. If I (or dedsm or anyone
 else) is motivated enough to submit a PR that adds the three-line public
 API (could also be a decorator) and modifies the docs accordingly, it
 would likely be accepted.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.b92b46bc5e922a04bef78e13e3ed0ba8%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-

Comment (by kristofclaes):

 I have changed `template` to `self.template`. If I understand the code
 correctly, this should work as well? Or is passing `template` to `as_sql`
 the preferred solution?

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.433bc9aab9917a565597c09f0ae5df49%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-

Comment (by manfre):

 Missed a mistake in the documentation example. Need to pass template to
 `as_sql` so that it is used.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.d19514f40684a19ba1c0fd626b2cdbe1%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-
Changes (by carljm):

 * stage:  Ready for checkin => Accepted


Comment:

 I don't think the code in the doc patch is quite right yet.

 Also, I'm inclined to agree with @dedsm above -- what's the harm in
 providing a public API that is effectively equivalent to doing this same
 monkey-patching "under the hood"( ;-) ). Seems like there'd be no harm,
 and it would give us more flexibility in the future if this does "become a
 more common problem."

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.680c5e7c847fa88b548d6274b2049dea%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-

Comment (by kristofclaes):

 I have created a PR to update the docs:
 https://github.com/django/django/pull/5574

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.9966f8f62aa1f4fb604ece89023d9f6b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-

Comment (by dedsm):

 wouldn't it be better if the BaseExpression had a public api for this
 instead of relying on third parties monkey patching by design?

 Something like:

 {{{
 from django.db.models import Sum

 def backend_sum(self, compiler, connection):
 #do stuff

 Sum.add_backend('firebird', backend_sum)
 }}}

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.829f0dc145601d5c9ffa7deb901fec04%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
-+-
 Reporter:  jarshwah |Owner:
 Type:   |  kristofclaes
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  0
-+-
Changes (by kristofclaes):

 * status:  new => assigned
 * owner:  nobody => kristofclaes


--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.716fd1f5a4dfb0ed0328771d234edcee%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-07 Thread Django
#25687: Document how backends should monkey patch expressions
--+
 Reporter:  jarshwah  |Owner:  nobody
 Type:  Cleanup/optimization  |   Status:  new
Component:  Documentation |  Version:  master
 Severity:  Normal|   Resolution:
 Keywords:| Triage Stage:  Accepted
Has patch:  0 |  Needs documentation:  0
  Needs tests:  0 |  Patch needs improvement:  0
Easy pickings:  1 |UI/UX:  0
--+
Changes (by timgraham):

 * type:  Uncategorized => Cleanup/optimization
 * easy:  0 => 1


Comment:

 It seems the "Technical Information" section of
 `docs/ref/models/expression.txt` is probably the place to add this.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.315f269a6a4cdd76f0943b7429bcdc2b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #25687: Document how backends should monkey patch expressions

2015-11-06 Thread Django
#25687: Document how backends should monkey patch expressions
---+
 Reporter:  jarshwah   |Owner:  nobody
 Type:  Uncategorized  |   Status:  new
Component:  Documentation  |  Version:  master
 Severity:  Normal |   Resolution:
 Keywords: | Triage Stage:  Accepted
Has patch:  0  |  Needs documentation:  0
  Needs tests:  0  |  Patch needs improvement:  0
Easy pickings:  0  |UI/UX:  0
---+
Changes (by dedsm):

 * cc: davidesousa@… (added)


--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.c3fa8bb0bbe00b40cd640655b84b0868%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


[Django] #25687: Document how backends should monkey patch expressions

2015-11-06 Thread Django
#25687: Document how backends should monkey patch expressions
-+
   Reporter:  jarshwah   |  Owner:  nobody
   Type:  Uncategorized  | Status:  new
  Component:  Documentation  |Version:  master
   Severity:  Normal |   Keywords:
   Triage Stage:  Accepted   |  Has patch:  0
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+
 @dedsm at djangounderthehood brought up that the docs do not currently
 contain information for how 3rd party backends should be supporting
 expressions by monkey patching. Let's fix that.

 Firebird backend (with connection.vendor == 'firebird') would change Sum
 like this:

 {{{
 from django.db.models import Sum

 def backend_sum(self, compiler, connection)
 # do stuff

 Sum.as_firebird = backend_sum

 }}}

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/051.306fcbffaff45c5507fd48e8dab07714%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.