UserManager documentation doesn't mention that it depends on date_joined
|Reported by:||semenov||Owned by:||nobody|
|Has patch:||no||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
The documentation at https://docs.djangoproject.com/en/dev/topics/auth/customizing/ says:
If your User model defines username and email fields the same as Django’s default User, you can just install Django’s UserManager.
This is not true in the sense that these are not the only required fields for Django's UserManager to be a drop-in replacement. One has also to define MyUser.date_joined, otherwise UserManager.create_user(..) would fail to create a user.
The documentation should be updated to reflect that date_joined field is also required to use Django's UserManager.
Change History (4)
comment:1 Changed 2 years ago by pegler
- Cc pegler@… added
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset
- Triage Stage changed from Unreviewed to Accepted
comment:2 Changed 20 months ago by Tim Graham <timograham@…>
- Resolution set to fixed
- Status changed from new to closed