Open stephenomalley opened 6 years ago
AUTHENTICATION_BACKENDS = ( 'social.backends.facebook.FacebookOAuth2', )
TEMPLATES = [ { 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': [TEMPLATE_PATH], 'APP_DIRS': True, 'OPTIONS': { 'context_processors': [ 'django.contrib.auth.context_processors.auth', 'social.apps.django_app.context_processors.backends', 'social.apps.django_app.context_processors.login_redirect', ], }, }, ]
I have the same problem
You using social_core.backends.facebook.FacebookOAuth2
in AUTHENTICATION_BACKENDS
, for this you have to put social_django
in INSTALLED_APPS
.
If you put this issue will be resolved.
You using
social_core.backends.facebook.FacebookOAuth2
inAUTHENTICATION_BACKENDS
, for this you have to putsocial_django
inINSTALLED_APPS
.If you put this issue will be resolved.
Perfect! I had removed social_django
but forgot to remove entries from AUTHENTICATION_BACKENDS
.
Not sure what I've done wrong, but in our app we get the error
TypeError: __init__() missing 1 required positional argument: 'strategy'
when running tests. It happens for the first test and seems to be caused by the__init__
method not being patched. It seems to only effect the first test run in our suite as on later tests the__init__
method is patched.If we add
from social_django import views
in the__init__.py
of our project root then the error doesn't appear. If we remove anysocial_core
backends
from outAUTHENTICATION_BACKENDS
list then the error doesn't occur. So the issue has a workaround, but I'm just wondering if there is something wrong with our set up.Here are our versions: Django==1.11.10 social-auth-app-django==2.1.0 social-auth-app-django-mongoengine==1.0.0 social-auth-core==1.7.0 social-auth-storage-mongoengine==1.0.1
Python 3.6.4
Our
settings.py
has the following setup:Full Stack trace of error: