You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am not sure if you are maintaining this package. I required a slider/carousel in one of my Django CMS projects and found about djangocms-slick-slider from Google.
Upon configuring the project I found out that this package isn't compatible with Django version > 4.0+. The module causing this error ugettext_lazy has been dropped from >Django 4.0. You can find the discussion over here: https://github.com/oesah/djangocms-slick-slider
Do you intend to maintain this repo or perform a fix?
What I Did
Installed djangocms_slick_slider
Added djangocms_slick_slider.apps.DjangocmsSlickSliderConfig in INSTALLED_APPS
Traceback (most recent call last):
File "/app/manage.py", line 22, in <module>
main()
File "/app/manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/usr/local/lib/python3.10/site-packages/django/core/management/__init__.py", line 442, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python3.10/site-packages/django/core/management/__init__.py", line 416, in execute
django.setup()
File "/usr/local/lib/python3.10/site-packages/django/__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/local/lib/python3.10/site-packages/django/apps/registry.py", line 116, in populate
app_config.import_models()
File "/usr/local/lib/python3.10/site-packages/django/apps/config.py", line 269, in import_models
self.models_module = import_module(models_module_name)
File "/usr/local/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/usr/local/lib/python3.10/site-packages/djangocms_slick_slider/models.py", line 2, in <module>
from django.utils.translation import ugettext_lazy as _
ImportError: cannot import name 'ugettext_lazy' from 'django.utils.translation' (/usr/local/lib/python3.10/site-packages/django/utils/translation/__init__.py)
Watching for file changes with StatReloader
Exception in thread django-main-thread:
Traceback (most recent call last):
File "/usr/local/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
self.run()
File "/usr/local/lib/python3.10/threading.py", line 953, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.10/site-packages/django/utils/autoreload.py", line 64, in wrapper
fn(*args, **kwargs)
File "/usr/local/lib/python3.10/site-packages/django/core/management/commands/runserver.py", line 125, in inner_run
autoreload.raise_last_exception()
File "/usr/local/lib/python3.10/site-packages/django/utils/autoreload.py", line 87, in raise_last_exception
raise _exception[1]
File "/usr/local/lib/python3.10/site-packages/django/core/management/__init__.py", line 394, in execute
autoreload.check_errors(django.setup)()
File "/usr/local/lib/python3.10/site-packages/django/utils/autoreload.py", line 64, in wrapper
fn(*args, **kwargs)
File "/usr/local/lib/python3.10/site-packages/django/__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/local/lib/python3.10/site-packages/django/apps/registry.py", line 116, in populate
app_config.import_models()
File "/usr/local/lib/python3.10/site-packages/django/apps/config.py", line 269, in import_models
self.models_module = import_module(models_module_name)
File "/usr/local/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/usr/local/lib/python3.10/site-packages/djangocms_slick_slider/models.py", line 2, in <module>
from django.utils.translation import ugettext_lazy as _
ImportError: cannot import name 'ugettext_lazy' from 'django.utils.translation' (/usr/local/lib/python3.10/site-packages/django/utils/translation/__init__.py)
The text was updated successfully, but these errors were encountered:
Dsujan
changed the title
Error seen in Django 4.2
Not compatible in Django 4.2
Jul 11, 2023
@Dsujan Thanks for bringing this to my attention. I won't have time to fix it anytime soon, but you can send me a PR if you want to fix it. Should be easy to do, just check for the version of django when we import this and change it to the new import if django version is > 3.
Description
Hi @oesah,
I am not sure if you are maintaining this package. I required a slider/carousel in one of my Django CMS projects and found about djangocms-slick-slider from Google.
Upon configuring the project I found out that this package isn't compatible with Django version > 4.0+. The module causing this error
ugettext_lazy
has been dropped from>Django 4.0
. You can find the discussion over here: https://github.com/oesah/djangocms-slick-sliderDo you intend to maintain this repo or perform a fix?
What I Did
djangocms_slick_slider.apps.DjangocmsSlickSliderConfig
inINSTALLED_APPS
python mange.py makemigrations && python manage.py migrate && python mange.py runserver
The text was updated successfully, but these errors were encountered: