[Django] #35150: Logout no longer supports GET method

11 views
Skip to first unread message

Django

unread,
Jan 28, 2024, 1:51:18 PM1/28/24
to django-...@googlegroups.com
#35150: Logout no longer supports GET method
-----------------------------------------+--------------------------------
Reporter: ClutchReboot | Owner: nobody
Type: Bug | Status: new
Component: HTTP handling | Version: 5.0
Severity: Normal | Keywords: LogoutView GET
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-----------------------------------------+--------------------------------
Problem: Following documentation, I tried using the LogoutView to logout
like I have in the past. Now that I'm using 5.0, it looks like things have
changed. It does not allow GET method calls.

Either we need to allow GET calls again or tutorial documentation needs
updated.

Documentation Code:
{{{
{% if user.is_authenticated %}
Hi {{ user.username }}!
<p><a href="{% url 'logout' %}" >Log Out</a></p>
{% else %}
<p>You are not logged in</p>
<a href="{% url 'login' %}">Log In</a>
{% endif %}
}}}


Code in question:
https://github.com/django/django/blob/2005530920e7c290bb1cf7d9ada155250faa81ad/django/contrib/auth/views.py#L129
--
Ticket URL: <https://code.djangoproject.com/ticket/35150>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jan 28, 2024, 2:08:26 PM1/28/24
to django-...@googlegroups.com
#35150: Logout no longer supports GET method
--------------------------------+--------------------------------------
Reporter: Clutch_Reboot | Owner: nobody

Type: Bug | Status: new
Component: HTTP handling | Version: 5.0
Severity: Normal | Resolution:

Keywords: LogoutView GET | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
--------------------------------+--------------------------------------
Comment (by Simon Charette):

Unsure which documentation code tutorial you are referring to
[https://docs.djangoproject.com/en/5.0/releases/4.1/#log-out-via-get but
the docs clearly mention how to upgrade].

What documentation are you referring to?
--
Ticket URL: <https://code.djangoproject.com/ticket/35150#comment:1>

Django

unread,
Jan 28, 2024, 2:17:53 PM1/28/24
to django-...@googlegroups.com
#35150: Logout no longer supports GET method
--------------------------------+--------------------------------------
Reporter: Clutch_Reboot | Owner: nobody
Type: Bug | Status: new
Component: HTTP handling | Version: 5.0
Severity: Normal | Resolution:
Keywords: LogoutView GET | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
--------------------------------+--------------------------------------
Comment (by Clutch_Reboot):

Disregard. I was using outdated documentation.
--
Ticket URL: <https://code.djangoproject.com/ticket/35150#comment:2>

Django

unread,
Jan 28, 2024, 2:29:49 PM1/28/24
to django-...@googlegroups.com
#35150: Logout no longer supports GET method
--------------------------------+--------------------------------------
Reporter: Clutch_Reboot | Owner: nobody
Type: Bug | Status: closed

Component: HTTP handling | Version: 5.0
Severity: Normal | Resolution: invalid

Keywords: LogoutView GET | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
--------------------------------+--------------------------------------
Changes (by Simon Charette):

* status: new => closed
* resolution: => invalid

--
Ticket URL: <https://code.djangoproject.com/ticket/35150#comment:3>

Reply all
Reply to author
Forward
0 new messages