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
The test test_login_required is currently failing at the point where settings are overridden:
withoverride_settings(LOGIN_URL="login"):
# Note: The "login" is a pattern name in accounts.urls.response=self.client.get(public_url, follow=True) # <------------------ Fails hereself.assertEqual(response.status_code, 200)
response=self.client.get(private_url, follow=True)
self.assertRedirects(response, login)
mezzanine/template/__init__.py:53: in render
context[parts[-1]] = tag_func(*args, **kwargs)
mezzanine/twitter/templatetags/twitter_tags.py:63: in tweets_default
query_type = settings.TWITTER_DEFAULT_QUERY_TYPE
mezzanine/conf/__init__.py:259: in __getattr__
editable_cache = self._get_editable(request=self._current_request)
mezzanine/conf/__init__.py:163: in _get_editable
editable_settings = self._editable_caches[request]
mezzanine/conf/__init__.py:254: in __getattr__
return getattr(django_settings, name)
.tox/py39-dj30/lib/python3.9/site-packages/django/conf/__init__.py:77: in __getattr__
val = getattr(self._wrapped, name)
.tox/py39-dj30/lib/python3.9/site-packages/django/conf/__init__.py:204: in __getattr__
raise AttributeError
E AttributeError
From my investigation it looks like when get is called the twitter_default tag is called somewhere in the template, which in turns reads from the settings, and that crashes the site witn an AttributeError for TWITTER_DEFAULT_QUERY_TYPE. It seems to me override_settings is breaking Mezzanine's editable settings machinery (specifically the _editable_caches mentioned in the traceback).
The text was updated successfully, but these errors were encountered:
The test
test_login_required
is currently failing at the point where settings are overridden:From my investigation it looks like when
get
is called thetwitter_default
tag is called somewhere in the template, which in turns reads from the settings, and that crashes the site witn anAttributeError
forTWITTER_DEFAULT_QUERY_TYPE
. It seems to meoverride_settings
is breaking Mezzanine's editable settings machinery (specifically the_editable_caches
mentioned in the traceback).The text was updated successfully, but these errors were encountered: