[Python-modules-commits] [python-social-auth] 04/32: Updated Bitbucket backend to use the UUID as the ID_KEY

Wolfgang Borgert debacle at moszumanska.debian.org
Sat Dec 24 15:13:45 UTC 2016


This is an automated email from the git hooks/post-receive script.

debacle pushed a commit to tag v0.2.12
in repository python-social-auth.

commit 0a4b744cacc0a5a5a5f586d1368f387b9b1187d8
Author: Mark Adams <mark at markadams.me>
Date:   Sun Jun 21 09:01:06 2015 -0500

    Updated Bitbucket backend to use the  UUID as the ID_KEY
    
    Reference:
    https://confluence.atlassian.com/display/BITBUCKET/Use+the+Bitbucket+REST+APIs#UsetheBitbucketRESTAPIs-uuid-mainUniversallyUniqueIdentifier(UUID)
---
 social/backends/bitbucket.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/social/backends/bitbucket.py b/social/backends/bitbucket.py
index 8bb083e..c057465 100644
--- a/social/backends/bitbucket.py
+++ b/social/backends/bitbucket.py
@@ -13,6 +13,10 @@ class BitbucketOAuth(BaseOAuth1):
     REQUEST_TOKEN_URL = 'https://bitbucket.org/api/1.0/oauth/request_token'
     ACCESS_TOKEN_URL = 'https://bitbucket.org/api/1.0/oauth/access_token'
 
+    # Bitbucket usernames can change. The account ID should always be the UUID
+    # See: https://confluence.atlassian.com/display/BITBUCKET/Use+the+Bitbucket+REST+APIs
+    ID_KEY = 'uuid'
+
     def get_user_details(self, response):
         """Return user details from Bitbucket account"""
         fullname, first_name, last_name = self.get_user_names(response['display_name'])

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/python-social-auth.git



More information about the Python-modules-commits mailing list