Dear Graham and django developers,

I talked about this in our team. The pace is to fast. We have about 
thousand urls mappings
that need to be changed to from reverse('mapp.views.foo.bar') to 
reverse(view_method).

We never jumped on the "give the URLs a name" wagon.

What do you gain be disabling this feature? Security is not a concern any 
more.

We think disabling this feature brings drawbacks without advantage.

Related topic:

Using classed_based_view_instance.url instead of 
reverse(classed_based_view_instance) 
would be nice. What do you think?

Quote from ticket 22384 
{{{
Marc mentioned in that ticket "Reversing by dotted path to view is just a 
bad idea."
}}}

Maybe it was a bad idea. It was a bad since reverse() was not lazy many 
versions ago.
This created recursive import errors reverse() got called during importing 
a python file.

Again: Please think about this decision again. I guess many people don't 
want to reformat
their code base just because some said it was "just a bad idea".

Regards,
  Thomas Güttler

Am Mittwoch, 15. April 2015 10:19:47 UTC+2 schrieb guettli:
>
> Today I realized that the ability to reverse using the Python path gets 
> deprecated
>
> My source: https://docs.djangoproject.com/en/1.8/ref/urlresolvers/#reverse
>
> Imagine you have a very clear directory structure and everyone knows this 
> in
> your company.
>
> The name of an url pattern is redundant. I like to avoid redundancy (DRY).
>
> I don't see the reasons behind this.
>
> The security issues are already solved: 
> https://www.djangoproject.com/weblog/2014/apr/21/security/#s-issue-unexpected-code-execution-using-reverse
>
> Please tell me the reason.
>
> One work around this would be to give each view the name of the import 
> path: name="common_structure.foo.bar"
> And if you don't allow dots: name="common_structure/foo/bar"
> But this looks not dirty.
>
>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/b6d682a8-0e2e-41db-9f01-d152624db79e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to