I have checked my authentification by going to tools>Authentification using password check and even did a OAuth check. The checked and approved status is set to my default bitbucket profile on source tree. Everytime I do a fetch on source tree it asks for a username and password and when inserting my password in anyway it says that it failed to login.
Exact error message :
Logon failed, use ctrl+c to cancel basic credential prompt.
remote: Invalid username or password
fatal: Authentication failed for 'https://Bfirstname.lastname@example.org/B--------/m----------.git/'
I dont know what more to do.
Managed to get help outside of this community help page. Nobody seems to be active here.
Posting my solution in the hopes that it helps somebody else in the future that has the same issue.
Problem : Something gets conflicted or corrupted in the saved passwords and authentification files.
1. In sourcetree -> tools -> Options -> Authentifications.
Clear everything, even not bitbucket related (Dont forget to write down your saved items to place back later)
2. Close sourcetree
Find a file called "passwd" and delete that.
4. Start Sourcetree
Go to Authentification again and insert the OAuth of your bitbucket (Be sure to be logged into bitbucket on your browser before you click Authenticate. )
5. Do a fetch on the repo giving you pains. It should ask you for your password. Once you have entered your password be patient, the fetch will take longer than usual but should work without constantly saying that you dont have correct username and password.
Hope this helps.
@altassian : Get your shite together man. According to google searches this bug has been active since early 2015. Its December 2018 man.
Looks like today was also my bimonthly Sourcetree auth headache. Sourcetree continuously asks for my password. I enter it, no luck. Password is still good as it works in a browser. I've created the auth token for this app in BitBucket and can successfully use it and login using other apps.
In addition to Bradley's instructions above, I also had to refresh my OAuth token.
Menu, Tools, Options, Authentication tab
Refresh OAuth Token button
I didn't get a chance to try the refresh w/o deleting everything first. Maybe that alone would have solved my problem.