Also, thank you again!

On Wednesday, June 19, 2013 3:16:05 PM UTC-5, Evan Stone wrote:
>
> Sure thing. Here are the snippets that gave me pause:
>
> "Think carefully before handling information not directly related to 
> authentication in your custom User Model.
>
> It may be better to store app-specific user information in a model that 
> has a relation with the User model. That allows each app to specify its own 
> user data requirements without risking conflicts with other apps...."
>
> along with
>
> "One limitation of custom User models is that installing a custom User 
> model will break any proxy model extending 
> User<https://docs.djangoproject.com/en/1.5/ref/contrib/auth/#django.contrib.auth.models.User>.
>  
> ..."
>
> and
>
> "Another limitation of custom User models is that you can’t use 
> django.contrib.auth.get_user_model()<https://docs.djangoproject.com/en/1.5/topics/auth/customizing/#django.contrib.auth.get_user_model>
>  as 
> the sender or target of "
>
>
>
>
> On Tuesday, June 18, 2013 6:34:16 PM UTC-5, Russell Keith-Magee wrote:
>>
>>
>> On Tue, Jun 18, 2013 at 11:37 PM, Evan Stone <[email protected]> wrote:
>>
>>> Russ, 
>>>
>>> Thanks so much for getting back to me! I shouldn't have posted that 
>>> without my code in front of me... (was posting from my phone, in bed) 
>>>
>>> It turns out that I did NOT have AUTH_USER_MODEL set. I had 
>>> AUTH_PROFILE_MODULE set.
>>>
>>
>> Ah - that'll do it :-) 
>>  
>>
>>> I changed it to AUTH_USER_MODEL and followed the custom user model 
>>> example in the docs. I was really reluctant to do so earlier because the 
>>> docs make it sound like everything is pain moving forward with a custom 
>>> user model. Is it?
>>>
>>  
>> There are some things you need to keep in mind, but they're generally 
>> complications because you can't rely on User having a 30 character username 
>> and option email address, and so on. The trivial solution will always to be 
>> the builtin User model, but as long as you're aware of the assumptions 
>> you're making about your user model, switching to a new User model 
>> shouldn't be too much pain at all. The changes required should be 
>> relatively obvious -- for example, you'll need a new form definition for 
>> any User-based forms, because Django can't know what fields are needed for 
>> *your* User model.
>>
>> Can you elaborate what aspect of the docs made you feel like the process 
>> of using a custom User model would be a pain? We added the feature because 
>> we feel it will be useful (and in my experience so far, it is). We want 
>> people to be aware that there will be complications, but we don't want to 
>> unilaterally scare people off. 
>>
>> Yours,
>> Russ Magee %-)
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to