﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
23515	AUTH_USER_MODEL and admin.E108	Wojciech Banaś	nobody	"Description of the problem:
In the administration panel you can not use relationships with the {{{__}}} lookup. 

I receive the following error:
{{{
<class 'admin.UserProfileAdmin'>: (admin.E108) The value of 'list_display[1]' refers to 'user__first_name', which is not a callable, an attribute of 'UserProfileAdmin', or an attribute or method on 'accounts.UserProfile'
}}}

Sample code that generates this error:

{{{#!python

class UserProfile(models.Model):

    user = models.OneToOneField(settings.AUTH_USER_MODEL, primary_key=True)

class UserProfileAdmin(admin.ModelAdmin):

    list_display = (
        'user__id', 'user__first_name', 'user__last_name', 'user__email',)

}}}


"	Bug	closed	contrib.admin	1.7	Normal	duplicate	admin AUTH_USER_MODEL		Unreviewed	0	0	0	0	0	0
