Re: #5188 and backwards-incompatible change (remove order_by from date-based generic views)

2007-08-19 Thread James Bennett

On Aug 17, 12:00 pm, Gary Wilson <[EMAIL PROTECTED]> wrote:
> Yes, I do not like the idea of adding a new order_by parameter
> either.  However, there is a bit of an issue involving the
> archive_index view though because it also uses a num_latest parameter,
> IMHO implying that the items will be sorted by date_field descending.

Hm.

Since archive_index is explicitly meant to provide the latest objects,
I could see keeping the order_by in that view, and making it clear in
the docs that it'll override any ordering you try to do on the
QuerySet before having to the view. But archive_year should drop its
explicit ordering for consistency with the other generic views.


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: #5188 and backwards-incompatible change (remove order_by from date-based generic views)

2007-08-17 Thread Gary Wilson

On Aug 17, 12:16 am, "James Bennett" <[EMAIL PROTECTED]> wrote:
> And I just realized I missed #3134, which argued for a slightly
> different solution, in the form of an 'order_by' parameter to the
> views.
>
> Personally, I think it's easier to just skip the parameter and rely on
> the fact that you can apply whatever ordering you like to the QuerySet
> before passing it to the view, but it's worth noting as an alternate
> proposal.

Yes, I do not like the idea of adding a new order_by parameter
either.  However, there is a bit of an issue involving the
archive_index view though because it also uses a num_latest parameter,
IMHO implying that the items will be sorted by date_field descending.

Gary


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: #5188 and backwards-incompatible change (remove order_by from date-based generic views)

2007-08-16 Thread James Bennett

And I just realized I missed #3134, which argued for a slightly
different solution, in the form of an 'order_by' parameter to the
views.

Personally, I think it's easier to just skip the parameter and rely on
the fact that you can apply whatever ordering you like to the QuerySet
before passing it to the view, but it's worth noting as an alternate
proposal.

-- 
"Bureaucrat Conrad, you are technically correct -- the best kind of correct."

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



#5188 and backwards-incompatible change (remove order_by from date-based generic views)

2007-08-16 Thread James Bennett

After being somewhat startled by the results of the archive_year
generic view and finding that the source of my confusion was an
explicit "order_by()" being done in that view, and finding another in
archive_index, I opened #5188 with a patch which removes these calls
to "order_by()".

I think the reasoning I've provided in the ticket is a good argument
for why we should make this change, but it would be
backwards-incompatible, since anyone who was relying on that behavior
will now need to apply ordering prior to handing a QuerySet over to
one of those views.

So... anyone have strong feelings against the change?


-- 
"Bureaucrat Conrad, you are technically correct -- the best kind of correct."

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---