Hi,

I want to add that it was very simple to upgrade Django from 1.11 to 2.0
and then to 2.1, I only had to change minor changes in my code - changing
to class-based views and updating my tests to reflect the 403 pages
(instead of a 302 redirect), so thanks for maintaining Django and for not
breaking too many things when upgrading Django from one version to another.

I hope you will agree to revert the changes done to ngettext_lazy and
ngettext in version 2.2 and then I will be able to upgrade Django to the
next LTS version.

אורי
u...@speedy.net


‪On Fri, Nov 1, 2019 at 10:18 AM ‫אורי‬‎ <u...@speedy.net> wrote:‬

> Django developers,
>
> I opened ticket https://code.djangoproject.com/ticket/30939 and I was
> referred to https://code.djangoproject.com/ticket/30439 as a duplicate. I
> don't understand why you need such a long formula to decide if a number is
> singular or plural. If it's 1 it's singular, otherwise it's plural. What's
> wrong about that?
>
> If you want to define a function with 4 strings for 4 different numbers,
> you should define a new function and not edit ngettext_lazy and ngettext.
> My code which works with all Django versions up to 2.1, breaks with Django
> 2.2. This issue prevents me from upgrading Django to 2.2. Is this change
> documented in the release notes? I didn't find it there. I would like to
> keep using ngettext_lazy with 2 strings (when the number is either 1 or not
> 1) and not with 4 strings. Actually I always use plural but because similar
> validators used ngettext_lazy (MinLengthValidator and MaxLengthValidator in
> django.core.validators) I also used it in my validators. But the number I'm
> using is never equal to 1.
>
> You can see my code here (search for "ngettext_lazy"):
>
> https://github.com/speedy-net/speedy-net/blob/master/speedy/core/accounts/validators.py
>
>
> And the relevant Django code:
>
> https://github.com/django/django/blob/master/django/core/validators.py#L348-L377
>
>
> אורי
> u...@speedy.net
>

-- 
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/CABD5YeGzsMT3D0JHcH-bEaS0YZm2kY%3DVHTRngDUq3Q%3D640jgLg%40mail.gmail.com.

Reply via email to