hugo wrote:
> >I like this idea, but I think that shortcuts of whatever should use
> >explicit imports such as
> [...]
> >This makes it a lot easier to tell what exactly you'll get if you
> >import django.shortcuts.
>
> Yes, most definitely. The "simplified API importer" should only do
> explicit imports of the stuff that should go in there, so that their
> namespace is really simple and doesn't contain any surprises. In a
> best-case scenario, they would _only_ include the names that are
> documented in the "simplified API". And we should try to reach that
> best-case scenario, if we really want to stick to the tagline "the web
> framework for _perfectionists_ with deadlines" ;-)

If the aim is to have a single import for simple views like:

from django.tasks.views import *

then that module should definitely do explicit imports from other
modules
so that it is easy to follow where things are coming from.

My idea with django.shortcuts was to contain the functions that wrap up
a bunch of Django functionality into a one-liner (render_to_response,
render_to_string, get_object_or_404).

Kieran

Reply via email to