Opened 4 years ago

Closed 4 years ago

#19079 closed Cleanup/optimization (fixed)

make USERNAME_FIELD a required attribute of user objects

Reported by: ptone Owned by: nobody
Component: contrib.auth Version: master
Severity: Release blocker Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


currently it is documented as required, but is not present in any base class

instead a number of places we fall back to looking for a 'username' attribute


it would clean things up a bit to simply require this as a defined attribute, and represent it appropriately on the base classes

Change History (2)

comment:1 Changed 4 years ago by russellm

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Severity changed from Normal to Release blocker
  • Triage Stage changed from Unreviewed to Accepted

I've got a patch to address this almost ready to go.

comment:2 Changed 4 years ago by Russell Keith-Magee <russell@…>

  • Resolution set to fixed
  • Status changed from new to closed

In c433fcb3fb34fccd69782979f0e7cd5f2d4a4893:

Fixed #19077, #19079 -- Made USERNAME_FIELD a required field, and modified UserAdmin to match.

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