Good choice. I wonder when weak password hashing in Django will be given the same exception.
Good choice. I wonder when weak password hashing in Django will be given the same exception.
I've also been looking at trying to make an username===email backend for django (instead of a user generated--part of the battle of avoiding too many user names that people just forget) and it's hard because a lot of things in the auth module are fairly fixed--regardless of the backend that you choose (for example, the regex on the username, or the length of fields). There have been some other attempts (like emailauth) to address this, but it's actually a large undertaking if you want the same functionality as the auth module.
How responsive are the django developers? They seemed fairly certain that they weren't going to change the defaults for the username/email address to preserve backwards compatibility. Is it better to make a whole new authorization module (complete with middleware) or to patch theirs?
Also, if you are cool with rolling your own registration forms/etc. you can easily just set the email as the username and email. You lose the more obscure but technically valid characters for email (a-z A-Z 0-9 @.+-_ are all fine), but 99% of emails work fine in the Django username field. Or maybe I just haven't hit some obvious problem with that implementation yet...
BUT The problem with forking contrib.auth to make say for example "gen_auth" is that the module is pretty good (so it's a lot of effort to maintain a fork and to stay current with the django trunk) and so far I've found that the following modules rely on it: comments sites sitemaps (perhaps) messages (ok, deprecated by 1.4, so I'll ignore it) flatpages (and I don't know how many other 3rd party packages).
It's not ideal, but the more I look at it, the more I'm leaning towards monkey_patching.
[1] http://stackoverflow.com/questions/2610088/can-djangos-auth-...