Re: Making URLconfs accept view objects, not just paths to views

2006-05-07 Thread wiktor
I do like it a lot,especially when written like this: @urlpattern('',r'^hello/$') def my_view(request): return HttpResponse('Hello world') or @simple_urlpattern( '','hello' ) def my_view(request): return HttpResponse('Hello world') Wiktor Sadowski --~--~-~--~~--

Re: Should the template system try to be a bit smarter about TypeError?

2006-05-07 Thread Kieran Holland
I don't understand why the TypeError needs to be caught at all. If the wrong number of arguments are passed then it seems to me that something is genuinely broken - is there some reason to mask it? FWIW I removed that catch as part of #1400 and haven't missed it. Kieran --~--~-~--~---

Should the template system try to be a bit smarter about TypeError?

2006-05-07 Thread James Bennett
While trying to answer a question in the IRC channel today, I was poking around in the template system and noticed that resolve_variable has a comment about a particularly odd "gotcha": because it catches and silently hides a TypeError raised by calling a method without the appropriate number of a

Re: Making URLconfs accept view objects, not just paths to views

2006-05-07 Thread Honza Král
+1 as well, seems more clear I would like to see all the strings (eg INSTALLED_APPS) replaced by the actual objects, but I am not sure whether its a) wise b) possible On 5/7/06, Jason Davies <[EMAIL PROTECTED]> wrote: > > +1. > > Seems more consistent and Pythonic. > > Cheers, > Jason > > > > >

Re: Making URLconfs accept view objects, not just paths to views

2006-05-07 Thread Jason Davies
+1. Seems more consistent and Pythonic. Cheers, Jason --~--~-~--~~~---~--~~ 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 unsubscri

Re: Making URLconfs accept view objects, not just paths to views

2006-05-07 Thread olive
+1 We already have to import models to use generic views, then, for the sake of consistency, it seems normal to have to import views as well. Yes, keep objects as objects everywhere is possible. --~--~-~--~~~---~--~~ You received this message because you are sub