models: Disable caching of supported_auth_backends for now.

This seems to be causing hard-to-debug test failures.
This commit is contained in:
Tim Abbott
2019-03-18 11:28:13 -07:00
parent 5f88406133
commit 58ca1ba5a4

View File

@@ -141,8 +141,9 @@ def get_active_realm_emoji_cache_key(realm: 'Realm') -> str:
supported_backends = None # type: Optional[Set[type]]
def supported_auth_backends() -> Set[type]:
global supported_backends
if supported_backends is None:
supported_backends = django.contrib.auth.get_backends()
# Caching temporarily disabled for debugging
supported_backends = django.contrib.auth.get_backends()
assert supported_backends is not None
return supported_backends
def clear_supported_auth_backends_cache() -> None: