Re: Why does get_profile exist?

2009-04-15 Thread mrts
On Apr 15, 11:04 am, David Cramer wrote: > I was never a fan of the profile model as it stands. It's not very > practical in every situation I've ever been in. Being that 1.0 was > supposed to be backwards compatible, and this is a public API I think > it needs to stay. > >

Re: Why does get_profile exist?

2009-04-15 Thread David Cramer
I was never a fan of the profile model as it stands. It's not very practical in every situation I've ever been in. Being that 1.0 was supposed to be backwards compatible, and this is a public API I think it needs to stay. I'd love to see a way to swap out the User model in the future though,

Re: Why does get_profile exist?

2009-04-13 Thread Glenn Maynard
On Tue, Apr 14, 2009 at 12:00 AM, James Bennett wrote: > Well, first of all user profiles aren't a "narrowly useful special > case" -- they're an extremely common feature needed on lots of > real-world sites. So having some sort of standard API for that is a > good thing.

Re: Why does get_profile exist?

2009-04-13 Thread James Bennett
On Mon, Apr 13, 2009 at 8:34 PM, Glenn Maynard wrote: > You don't need to come up with helpers--OneToOneField automatically > creates the only helper this provides, in a way that (unlike > get_profile()) is consistent with all other model relationships.  It's >

Re: Why does get_profile exist?

2009-04-13 Thread Glenn Maynard
On Mon, Apr 13, 2009 at 8:55 PM, James Bennett wrote: > It's true you *might* want to do it for any particular model, but the > specific case of user profiles is such a common situation that it > seems a shame to require everybody to come up with their own system > and

Re: Why does get_profile exist?

2009-04-13 Thread James Bennett
On Mon, Apr 13, 2009 at 7:32 PM, Glenn Maynard wrote: > Well, you might want to do that for any model, and the admin API > provides a more generic approach to managing this sort of task--but > OK. It's true you *might* want to do it for any particular model, but the

Re: Why does get_profile exist?

2009-04-13 Thread Glenn Maynard
On Mon, Apr 13, 2009 at 8:02 PM, James Bennett wrote: > user -- they behaved more like normal attributes. At that point > get_profile() could have been refactored into a read-only property, > but there really weren't any pressing API-design reasons for doing so. Sure;

Re: Why does get_profile exist?

2009-04-13 Thread Waylan Limberg
On Mon, Apr 13, 2009 at 4:30 PM, Glenn Maynard wrote: > > Why do get_profile() and AUTH_PROFILE_MODULE exist, instead of just > declaring the Profile to User relationship as OneToOne and using the > auto-generated User.profile relationship? > Well, prior to qs-refactor

Re: Why does get_profile exist?

2009-04-13 Thread Glenn Maynard
On Mon, Apr 13, 2009 at 4:50 PM, Adi Sieker wrote: >> Why do get_profile() and AUTH_PROFILE_MODULE exist, instead of just >> declaring the Profile to User relationship as OneToOne and using the >> auto-generated User.profile relationship? > > Probably because third party apps

Re: Why does get_profile exist?

2009-04-13 Thread Adi Sieker
Hi, On 13.04.2009, at 22:30, Glenn Maynard wrote: > > Why do get_profile() and AUTH_PROFILE_MODULE exist, instead of just > declaring the Profile to User relationship as OneToOne and using the > auto-generated User.profile relationship? > > I just changed my Profile's User relationship from

Re: Why does get_profile exist?

2009-04-13 Thread Adi Sieker
On 13.04.2009, at 22:30, Glenn Maynard wrote: > > Why do get_profile() and AUTH_PROFILE_MODULE exist, instead of just > declaring the Profile to User relationship as OneToOne and using the > auto-generated User.profile relationship? Probably because third party apps can then get the user

Why does get_profile exist?

2009-04-13 Thread Glenn Maynard
Why do get_profile() and AUTH_PROFILE_MODULE exist, instead of just declaring the Profile to User relationship as OneToOne and using the auto-generated User.profile relationship? I just changed my Profile's User relationship from ForeignKey to OneToOne (the docs say to use ForeignKey, not