{"action":"opened","issue":{"url":"https://api.github.com/repos/omab/python-social-auth/issues/771","labels_url":"https://api.github.com/repos/omab/python-social-auth/issues/771/labels{/name}","comments_url":"https://api.github.com/repos/omab/python-social-auth/issues/771/comments","events_url":"https://api.github.com/repos/omab/python-social-auth/issues/771/events","html_url":"https://github.com/omab/python-social-auth/issues/771","id":112866842,"number":771,"title":"Error while saving extra_data for new users","user":{"login":"dragomireckijj","id":6287067,"avatar_url":"https://avatars.githubusercontent.com/u/6287067?v=3","gravatar_id":"","url":"https://api.github.com/users/dragomireckijj","html_url":"https://github.com/dragomireckijj","followers_url":"https://api.github.com/users/dragomireckijj/followers","following_url":"https://api.github.com/users/dragomireckijj/following{/other_user}","gists_url":"https://api.github.com/users/dragomireckijj/gists{/gist_id}","starred_url":"https://api.github.com/users/dragomireckijj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dragomireckijj/subscriptions","organizations_url":"https://api.github.com/users/dragomireckijj/orgs","repos_url":"https://api.github.com/users/dragomireckijj/repos","events_url":"https://api.github.com/users/dragomireckijj/events{/privacy}","received_events_url":"https://api.github.com/users/dragomireckijj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-22T18:49:50Z","updated_at":"2015-10-22T18:49:50Z","closed_at":null,"body":"I've got **AttributeError** at `/complete/facebook/` just before redirecting newly registered user to `LOGIN_REDIRECT_URL`: Exception Value: 'str' object has no attribute 'update'\r\n\r\n- Request Method: GET\r\n- Request URL: http://appdomain/complete/facebook/?redirect_state=~&code=~&state=~\r\n- Django Version: 1.9\r\n- Python Version: 2.7.6\r\n- Installed Applications:\r\n  - 'django.contrib.admin',\r\n  - 'django.contrib.auth',\r\n  - 'django.contrib.contenttypes',\r\n  - 'django.contrib.sessions',\r\n  - 'django.contrib.messages',\r\n  - 'django.contrib.staticfiles',\r\n  - 'django.contrib.gis',\r\n  - 'social.apps.django_app.default',\r\n  - 'myapp'\r\n- Installed Middleware:\r\n  - 'django.contrib.sessions.middleware.SessionMiddleware',\r\n  - 'django.middleware.common.CommonMiddleware',\r\n  - 'django.middleware.csrf.CsrfViewMiddleware',\r\n  - 'django.contrib.auth.middleware.AuthenticationMiddleware',\r\n  - 'django.contrib.auth.middleware.SessionAuthenticationMiddleware',\r\n  - 'django.contrib.messages.middleware.MessageMiddleware',\r\n  - 'django.middleware.clickjacking.XFrameOptionsMiddleware',\r\n  - 'django.middleware.security.SecurityMiddleware']\r\n\r\nTraceback:\r\n\r\nFile \".../social/pipeline/social_auth.py\" in load_extra_data\r\n`  92.         social.set_extra_data(extra_data)`\r\n\r\nFile \".../social/storage/django_orm.py\" in set_extra_data\r\n`  16.         if super(DjangoUserMixin, self).set_extra_data(extra_data)`\r\n\r\nFile \".../social/storage/base.py\" in set_extra_data\r\n`  85.                 self.extra_data.update(extra_data)`\r\n\r\nUser and related social auth was created correctly, except `extra_data` field of `UserSocialAuth` model (it was empty JSON string). Every next attempt was competed without any errors, updating `extra_data` field with facebook related data in JSON format.\r\n\r\nError appears again if User and related UserSocialAuth models are removed. Seems like `set_extra_data` function assumes `self.extra_data` to be **dict**, but **str** given for new users.\r\n\r\nMy app is default django project appended using PSA documentation guides."}}