Anthony:

Didn't seem right to me either...

*>By default, the username field has an IS_MATCH and and IS_NOT_IN_DB 
validator, *
. I did see the web2py  regex for that somewhere. and noticed the 
appropriate validators.

*Here is what I tested: (using user names)*

0- start a blank web2py app with only this:

auth.define_tables(username=True)
## create all tables needed by auth if not custom tables
auth.define_tables()
auth.settings.table_user.username.requires=IS_MATCH('[a-z].*', error_message
='letters only')



1- sign up user: jsmith with email jsmith[at]gmail.com
     - examine user's profiile.. all is well.

2- Then, log out

3- Try to register him again, and it will not work because of the duplicate 
email address,
    *but if I changed the email address to ,  jsmithxxx[at]gmail.com *
   and left user name *jsmith* -  AND enter a new password, not jsmith's 
 password, it lets me in
    to jsmith's original account.

I just tried it again, and I believe that *without* the 
IS_NOT_IN_DB it behaves this way.

Maybe I'm doing something wrong... when I add the IS_NOT_IN_DB validator, 
it all behaves the way I want.

Hope that helps explain what I observed.

Thanks
Rob


-- 



Reply via email to