Not sure if this is where I should comment on this issue but I just
upgraded to Django 1.8 and am encountering this error:
RedirectCycleError: Redirect loop detected.
I have a view that looks for a certain condition. If that condition is not
met then I redirect to a second view. That second view does something then
most of the time will redirect back to the first view. This works well in
reality, but in testing results in 'RedirectCycleError: Redirect loop
detected' when the second view redirects back to the first.
On Saturday, 2 May 2015 03:36:32 UTC+10, Mounir Messelmeni wrote:
>
> This is related to the ticket #24713, I'm trying to fix this issue and I
> was thinking about using a variable to know how much time a single url can
> be repeated on the redirects.
> Is two time sufficient or we will have another case that need 3 times.
> If you agree using a variable is it okay to pass it like the follow on the
> get/post/head/trace/put method of the test client (max_page_redirect) and
> make it by default 2 or store it on the settings ?
>
> def put(self, path, data='', content_type='application/octet-stream',
> follow=False, max_page_redirect=2,
> secure=False, **extra):
> """
> Send a resource to the server using PUT.
> """
> response = super(Client, self).put(path, data=data,
> content_type=content_type,
> secure=secure, **extra)
> if follow:
> response = self._handle_redirects(response, max_page_redirect,
> **extra)
> return response
>
>
>
--
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 https://groups.google.com/group/django-developers.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-developers/3589fb63-6e16-4494-a133-772733780247%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.