Defaults to ``LOGIN_ERROR_URL``.
+- The app catches any exception and logs errors to ``logger`` or
+ ``django.contrib.messagess`` app. Having tracebacks is really useful when
+ debugging, for that purpose this setting was defined::
+
+ SOCIAL_AUTH_RAISE_EXCEPTIONS = DEBUG
+
+ It's default value is ``DEBUG``, so you need to set it to ``False`` to avoid
+ tracebacks when ``DEBUG = True``.
+
-----------------------
Authentication Pipeline
Defaults to ``LOGIN_ERROR_URL``.
+- The app catches any exception and logs errors to ``logger`` or
+ ``django.contrib.messagess`` app. Having tracebacks is really useful when
+ debugging, for that purpose this setting was defined::
+
+ SOCIAL_AUTH_RAISE_EXCEPTIONS = DEBUG
+
+ It's default value is ``DEBUG``, so you need to set it to ``False`` to avoid
+ tracebacks when ``DEBUG = True``.
.. _Model Manager: http://docs.djangoproject.com/en/dev/topics/db/managers/#managers
.. _Login URL: http://docs.djangoproject.com/en/dev/ref/settings/?from=olddocs#login-url
DEFAULT_REDIRECT = setting('SOCIAL_AUTH_LOGIN_REDIRECT_URL') or \
setting('LOGIN_REDIRECT_URL')
LOGIN_ERROR_URL = setting('LOGIN_ERROR_URL', setting('LOGIN_URL'))
+RAISE_EXCEPTIONS = setting('SOCIAL_AUTH_RAISE_EXCEPTIONS', setting('DEBUG'))
def dsa_view(redirect_name=None):
try:
return func(request, backend, *args, **kwargs)
except Exception, e: # some error ocurred
- if setting('DEBUG'):
+ if RAISE_EXCEPTIONS:
raise
backend_name = backend.AUTH_BACKEND.name