Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

SourceTree cannot connect to BitBucket cloud - SDNetDomain error 7.

euroBosch July 11, 2016

All of a sudden SourceTree Mac app could not retrieve my remote repositories but throwing error instead:

Login failed for your Bitbucket account.

The remote service said: 'The operation couldn’t be completed. (SDNetDomain error 7.)
'

I changed the password several times, updated the account, I even switched to Atlassian account (which I now cannot revert), tried SSH instead of HTTPS, all to no avail. 

I've seen this question asked several times but with no answers. 

Guys, what is going on? We cannot get our work done!

 

PS: I received several emails from BitBucket in the past few weeks stating that my account has been compromised so I changed the password several times but none of them works for SourceTree although I can succesfully login through the web app.

8 answers

10 votes
Gihan Karunarathne August 19, 2016

I fixed this issue by creating a new App Password.

I have activated Two-step verification ago. This may cause the issue.

You can create a App password by;

  1. Go to Bitbucket Settings
  2. Select Access Management >> App Passwords
  3. Create a new password by click on Create New Password
  4. Copy the password and give it for Sourcetree instead of your Bitbucket password.

 

Grant Kemp August 21, 2016

I tried that but it didn't work for me. 

 

Raj P August 23, 2016

This worked for me the second time around. Had to quit SourceTree and start it up again but once I put in my username and generated password, (on a Mac) it asked for my keychain access for my Bitbucket account and seemed to connect fine to my remote repos.

Jos September 30, 2016

SourceTree stopped working suddenly. I had merged Atlassian and BitBucket account and that worked for weeks and then suddenly stopped working. 

This solution worked for me. Thanks! 

Air Apps October 7, 2016

Thanks, works like a charm.

After created App Password, on a Mac, I opened Sourcetree, clicked at setting icon, settings, remove account listed and add your account again.

 

Alex Rodriguez October 31, 2016

Only worked for me after I edited my "Bitbucket Cloud" account in my remote repositories setting in SourceTree. I didn't delete it but just used the "edit account" button and updated the password.

Before doing this you must create an "App Password" on Bitbucket.

Ryan Ault November 10, 2016

SOLVED: @Air Apps method worked for me

geraintp November 26, 2016

Ye worked for me too, but it took a few minutes for the app password to kick in, and failed the first couple of tries.

3 votes
cdurieux August 17, 2016

Same issue . 

It appears after Atlassian Auth services merge (Bitbucket/Jira). 

 

Grant Kemp August 21, 2016

Agreed - they haven't migrated our emails properly. 

3 votes
Todd Prouty July 29, 2016

I still don't know why authentication isn't working through SourceTree in these specific cases, but I did find a workaround. If you add the the remote via the command line it will work in SourceTree. This article is a simple overview of adding a remote that way if you're not familiar with it (it's a GitHub article but not GitHub-specific).

Here are the steps I followed (and this assume you already have public key authentication set up with your Git host):

  1. Delete the existing remote link, either via SourceTree or the CLI (assumes a remote named 'origin'): 

    git remote rm origin
  2. Add remote via the CLI: 

    git remote add origin https://bitbucket.org/user/repo.git
  3. Test to verify: 

    git remote -v

    The remote should be listed.

  4. View the repository in SourceTree. The remote should be listed there (click 'show' in the sidebar).
  5. Try a push or pull. The first time I did a push I was prompted for username/password. Entering the Atlassian credentials did the trick. 

This worked for me with two repositories. Good luck!

Luís De Marchi January 12, 2017

Perfect

2 votes
euroBosch July 11, 2016

Apparently, if I use git pull it works if I use the Atlassian account, not the BitBucket acount.

Still, SourceTree cannot connect.

euroBosch July 11, 2016

Actually SourceTree does not allow logging in with email address (like Atlassian account) but only with Bitbucket username which cannot be used anymore, apparently. 

Maybe this could be the issue?

Todd Prouty July 29, 2016

I'm having the same issue you are, did you find a solution? This started happening after I switched to an Atlassian account. I've seen the error regarding using an email address, but the username doesn't work, either.

1 vote
BootMaker September 1, 2018

In SourceTree simply opened Settings and changed the protocol from Https to ssh and it works without any account and password change

Robin Leysen September 4, 2018

Tried Basic Authentication, OAuth, with and without app password. Finally decided to go with SSH, and this works for me.

1 vote
cdurieux August 17, 2016

I Disabled 2 step auth, deleted local repo, then cloned it from remote. All is working again smile

Grant Kemp August 21, 2016

This didn't work for me - I still get the above error 

1 vote
Grant Kemp August 4, 2016

I have got this as well. Never had this issue before. Looks like a bug. 

Can't even browse repos on Bitbucket. 

It looks like they migrated my accout to Atlassian - but the new Atlassian login doesn't work with Bitbucket if you have 2 step authentication enabled. 

 

What a mess !  !! 

0 votes
acurrieclark August 12, 2016

Same error here after switching to an Atlassian account.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events