Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace uggettext_lazy with gettext_lazy to support Django 4.0 #34

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

za
Copy link
Contributor

@za za commented Jul 16, 2022

django.utils.translation.ugettext(), ugettext_lazy(), ugettext_noop(),
ungettext(), and ungettext_lazy() are removed.

https://docs.djangoproject.com/en/4.0/releases/4.0/#features-removed-in-4-0

Django trac ticket: https://code.djangoproject.com/ticket/30165

@za
Copy link
Contributor Author

za commented Aug 16, 2022

Hi @kbytesys do you have any comment/feedback on this PR? Thank you.

@thisisayush
Copy link

+1 on this, this is needed!

@valbertovc
Copy link

+1 will be a great improvement.

@subaquatic-pierre
Copy link

+1 Please update this!

Copy link

@subaquatic-pierre subaquatic-pierre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good

@za
Copy link
Contributor Author

za commented Aug 18, 2023

Oh, it's been a year. Can we merge it soon? @subaquatic-pierre

@iRhonin
Copy link

iRhonin commented May 28, 2024

+1

@becory
Copy link

becory commented Oct 14, 2024

@kbytesys Can you merge it? I have this problem, too.

@za
Copy link
Contributor Author

za commented Oct 14, 2024

✏️ FTR currently, Django stable version is 5.x.x

@becory
Copy link

becory commented Oct 14, 2024

This is the solution I found to add this code to resolve this problem until it is merged.

add them in settings.py in front of "INSTALLED_APPS" variable.

import django.utils.translation as original_translation
from django.utils.translation import gettext_lazy

original_translation.ugettext_lazy = gettext_lazy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants