Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HP-2280 | Django 5.0 admin logout support #96

Merged
merged 1 commit into from
Mar 14, 2024
Merged

Conversation

charn
Copy link
Contributor

@charn charn commented Mar 13, 2024

This PR will add support for logout in Django admin (for Django 5.0). The ability to log out via GET requests in the django.contrib.auth.views.LogoutView and django.contrib.auth.views.logout_then_login() was removed in Django 5.0.

@charn charn requested a review from a team March 13, 2024 18:28
- use POST for social auth logout on Django admin login page
- django admin site returns logoutview response instead of redirect

Django 5.0 has removed the ability to log out via GET requests
in the django.contrib.auth.views.LogoutView
and django.contrib.auth.views.logout_then_login().

Refs: HP-2280, https://docs.djangoproject.com/en/5.0/releases/5.0/
@charn charn force-pushed the HP-2280-logout-fix branch from f44762e to aa963e0 Compare March 13, 2024 18:30
Copy link

codecov bot commented Mar 13, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 56.12%. Comparing base (29e4b2a) to head (aa963e0).

Files Patch % Lines
helusers/admin_site.py 50.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master      #96      +/-   ##
==========================================
- Coverage   56.21%   56.12%   -0.10%     
==========================================
  Files          31       31              
  Lines        1062     1062              
==========================================
- Hits          597      596       -1     
- Misses        465      466       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@charn charn merged commit b031c80 into master Mar 14, 2024
5 of 7 checks passed
@charn charn deleted the HP-2280-logout-fix branch March 14, 2024 09:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants