Hi Arthur,

I would recommend users of Django to use only lowercase usernames. And if
they insist that the username is an email address, also convert it to
lowercase. Otherwise you can have 3 separate users uri, Uri, and uRI, or 3
separate users with email addresses u...@example.com, u...@example.com, and
u...@example.com (or even u...@example.com). Maybe it's better to add an
optional setting to enforce usernames to be lowercase. And by the way also
alphanumeric. You don't want "!@#" to be a username on your system (or the
user's name in Chinese or Hebrew).

It's interesting that this ticket is 15 years old and still not completely
resolved.

By the way, when people type their email address, some programs (including
browsers) convert the first letter to uppercase, and I have received email
addresses from people with the first letter in uppercase, although their
true address is lowercase. I don't think you want this uppercase letter to
appear on your database in the email field.

אורי
(Uri)

u...@speedy.net


On Sun, Dec 12, 2021 at 6:02 PM Arthur Pemberton <pemb...@gmail.com> wrote:

> Especially with the ability to set USERNAME_FIELD to "email", it would be
> really useful to at least have a well documented warning that usernames are
> case-sensitive in Django.
>
> I've been using Django for years, and even I forget that fact some times.
> Until I start Googling and come across [1].
>
> Ideally, it would be great to have a setting (or model field) that would
> allow easy switching to case insensitive usernames.
>
> Arthur Pemberton
>
> ----
>
> [1] https://code.djangoproject.com/ticket/2273
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/9a5e1df3-778d-4993-8c32-57870fafd8f9n%40googlegroups.com
> <https://groups.google.com/d/msgid/django-developers/9a5e1df3-778d-4993-8c32-57870fafd8f9n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CABD5YeHyBPNvwk-nVonZDYg%3DSeR53uAT2-GZQWpBGDyMRf1W2Q%40mail.gmail.com.

Reply via email to