Sourcetree OFTEN can't connect SAML-based accounts

Issue #16712 resolved
Ben Low
created an issue

My Bitbucket account is now authenticated via SAML. When attempting to add the account in Sourcetree, Sourcetree OFTEN fails to detect the completion of successful auth flow, with the only option available to 'cancel'. Result: I can't add the account to Sourcetree.


  • Sourcetree 2.7.6 on macOS
  1. open Sourcetree > preferences > Accounts
  2. click Add...
  3. host: Bitbucket; auth type: OAuth; username: "no account connected"
    - click 'Connect Account'
  4. a modal dialog/sheet opens titled "Please sign in to this account:"
    - enter email, get redirected to my SAML provider (AzureAD), authenticate
    - after successful authentication, the modal dialog presents the default web view (list of repos), with no means to complete the process (ref attached screen shot)
    - with no other option, click Cancel

Note that this is not 100% reproducible, it was happening all morning (~6 attempts) but in the very last one where I was creating the above repro steps, it worked - the dialog closed and the account was added.

Comments (7)

  1. Gareth Jones

    Just spent an hour creating/revoking OAuth access and application passwords, trying to log into my Bitbucket account from Sourcetree only to repeatedly watch it fail to recognise the successful login. As above, my only option is the Cancel button and that kills the whole thing, forcing me to start again.

    I then uninstalled the whole app and re-installed it. Now I can't even register the bastard because when I log in during registration, it fails to recognise the login and the Continue button does nothing. I'm left with no option but to quit the registration process, which of course prevents Sourcetree from even running.

    Why do you guys have such problems getting this to work reliably? It's been flaky for several revisions.

    Update: I uninstalled a final time and installed 2.7.1. That version logged in OK.

    Come on guys, sort it out.

  2. Log in to comment