Ryan,

May be I'm missing something, but why not use a UserProfile model and
reference *it* instead of the User:

class UserProfile(db.Model):
    user = db.UserProperty()
    ...

UserProfile would use a generated integer key id, or a custom key_name
(e.g. a prefixed uuid4 string).

You would then reference the user profile in your models:

class Comment(db.Model):
    who = db.ReferenceProperty(reference_class=UserProfile)

If the user changes her e-mail, the references will not not affected.

app-engine-patch has built-in support for this, if you are using
Django you might want to take a look:
http://code.google.com/p/app-engine-patch/wiki/GoogleAccounts

On Nov 7, 7:12 am, Ryan Lamansky <[EMAIL PROTECTED]> wrote:
> yejun: I want to use Google's authentication system, not make my own.
>
> Mike Wesner: Your solution fails if the user changes their email
> address.  Read my whole post.  If, following your design, the user
> changes their email address, it'll look like a new user with a new key
> and everything... causing them to become disconnected with everything
> attached to their old address/key/whatever.
>
> -Ryan
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to