On Sun, Aug 2, 2009 at 8:05 PM, Brent Hagany<[email protected]> wrote: > > Hello Django devs, > > The issue of making shortcuts better (and decreasing the number of > imports in views.py files) was brought up at DjangoCon, and now that > 1.1 is out the door, I would like to spark some discussion on what > direction (if any) Django should take on the subject. (Relevant video > here: > http://www.youtube.com/watch?v=M1Qr9rSBGBE&feature=PlayList&p=D415FAF806EC47A1&index=2#t=36m15s) > > If you watch the video, there was some disagreement with the idea > right from the start. The ticket that grew out of that part of the > discussion is #8950, and has been marked Someday/Maybe. You may also > want to reference #9081, where I have been discussing the issue with > Chris Cahoon and Malcolm. But, just to be explicit, I don't want to > limit the discussion just to that patch, or to render_to_response or > any particular shortcut. First, we should discuss the larger issue of > whether technically unnecessary code (which is what any shortcut is) > should be allowed into Django, in my opinion. > > I am in favor of expanding shortcuts, if it's not obvious already. > Now, somebody disagree! > > >
I don't have a problem with putting shortcut functions in, like the redirect one Jacob added for 1.1. However I'm a massive -1 on adding a place for common imports like Simon proposed. All that does is obscure the location of the source code by adding an extra layer of indirection. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire "The people's good is the highest law." -- Cicero "Code can always be simpler than you think, but never as simple as you want" -- Me --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to [email protected] 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 -~----------~----~----~----~------~----~------~--~---
