django.core.cache.backends.memcached.MemcachedCache backend is removed

Bug #2039225 reported by Corey Bryant
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
In Progress
Undecided
Unassigned
OpenStack Dashboard Charm
In Progress
High
Unassigned
Ubuntu Cloud Archive
Status tracked in Bobcat
Bobcat
Triaged
High
Unassigned
horizon (Ubuntu)
Status tracked in Mantic
Mantic
Triaged
High
Unassigned

Bug Description

In 4.1 the django.core.cache.backends.memcached.MemcachedCache backend is removed.

https://github.com/django/django/blob/main/docs/releases/4.1.txt#L749

It's been deprecated since 3.2:

https://docs.djangoproject.com/en/4.2/releases/3.2/#features-deprecated-in-3-2

"The django.core.cache.backends.memcached.MemcachedCache backend is deprecated as python-memcached has some problems and seems to be unmaintained. Use django.core.cache.backends.memcached.PyMemcacheCache or django.core.cache.backends.memcached.PyLibMCCache instead."

This results in the following error on Ubuntu Mantic:

InvalidCacheBackendError at /
Could not find backend 'django.core.cache.backends.memcached.MemcachedCache': Module "django.core.cache.backends.memcached" does not define a "MemcachedCache" attribute/class
Request Method: GET
Request URL: http://10.5.3.66/horizon/
Django Version: 4.2.4
Exception Type: InvalidCacheBackendError
Exception Value:
Could not find backend 'django.core.cache.backends.memcached.MemcachedCache': Module "django.core.cache.backends.memcached" does not define a "MemcachedCache" attribute/class
Exception Location: /usr/lib/python3/dist-packages/django/core/cache/__init__.py, line 49, in create_connection
Python Executable: /usr/bin/python3
Python Version: 3.11.6
Python Path:
['/usr/lib/python3/dist-packages',
 '/usr/lib/python311.zip',
 '/usr/lib/python3.11',
 '/usr/lib/python3.11/lib-dynload',
 '/usr/local/lib/python3.11/dist-packages',
 '/usr/lib/python3/dist-packages',
 '/usr/lib/python3/dist-packages/openstack_dashboard']
Server time: Thu, 12 Oct 2023 20:44:30 +0000

description: updated
description: updated
description: updated
Revision history for this message
Corey Bryant (corey.bryant) wrote :

If the horizon package fix is needed before the SRU lands, it is available in https://launchpad.net/~corey.bryant/+archive/ubuntu/mantic-bobcat

Changed in horizon (Ubuntu Mantic):
status: New → Triaged
importance: Undecided → High
Changed in charm-openstack-dashboard:
status: New → Triaged
importance: Undecided → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-openstack-dashboard (master)
Changed in charm-openstack-dashboard:
status: Triaged → In Progress
Revision history for this message
Takashi Kajinami (kajinamit) wrote :

There is a patch to update the default cache backend. We can probably use it.
 https://review.opendev.org/c/openstack/horizon/+/891828

Changed in horizon:
status: New → In Progress
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.