Opened 8 weeks ago

Closed 8 weeks ago

#36561 closed Bug (fixed)

aupdate_session_auth_hash is raising SynchronousOnlyOperation

Reported by: Xdynix Owned by: Xdynix
Component: contrib.auth Version: 5.2
Severity: Normal Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

In aupdate_session_auth_hash the source code is

if hasattr(user, "get_session_auth_hash") and request.user == user:

which will raise SynchronousOnlyOperation error when used in an async view. It should be await request.auser() instead.

Change History (6)

comment:1 by Xdynix, 8 weeks ago

Easy pickings: set
Owner: set to Xdynix
Status: newassigned

comment:2 by Xdynix, 8 weeks ago

Summary: `aupdate_session_auth_hash` is using `request.user`aupdate_session_auth_hash is raising SynchronousOnlyOperation

comment:3 by Xdynix, 8 weeks ago

Has patch: set

comment:4 by Sarah Boyce, 8 weeks ago

Triage Stage: UnreviewedAccepted

comment:5 by Sarah Boyce, 8 weeks ago

Triage Stage: AcceptedReady for checkin

comment:6 by Sarah Boyce <42296566+sarahboyce@…>, 8 weeks ago

Resolution: fixed
Status: assignedclosed

In cd7554e:

Fixed #36561 -- Used request.auser() in contrib.auth.aupdate_session_auth_hash().

Note: See TracTickets for help on using tickets.
Back to Top