I have been trying to use the AbstractUser to add on a few fields to the standard django user. However while going through the motions, I came across a issue. When I tried to make my migrations a "Value Error: too many values to unpack" would result.
Here is my code:
models.py
class TeamMember(AbstractUser):
YEAR_LEVELS = (
('1', '1st'),
('2', '2nd'),
('3', '3rd'),
('4', '4th'),
('5', '5th'),
('0', 'Other'),
)
SAILING_LEVELS = (
('1', 'Beginner'),
('2', 'Intermediate'),
('3', 'Race'),
)
year_level = models.CharField(max_length = 1, choices=YEAR_LEVELS)
sailing_level = models.CharField(max_length = 1, choices=SAILING_LEVELS)
board_pos = models.CharField(max_length = 50)
avatar = models.URLField()
settings.py
AUTH_USER_MODEL = 'main.models.Users'
SOCIAL_AUTH_USER_MODEL = 'main.models.TeamMember'
I am also using python-social-auth which is what the second line in the settings.py file is for.