Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Atlassian Bitbucket Sourcetree Git Credential Manager prompt

Atlassian Bitbucket Sourcetree Git Credential Manager keeps prompting me to authenticate.

I have tried several fixes, including the obvious:

  • Entering auth, prompt re-appeared in 15 sec.

  • Deleting all saved passwords. -Didnt work for me, prompt re-appeared in 2-3 min.

  • Updating Git Cred mngr - no effect

  • Updating Sourcetree - no effect

  • Reinstalling services - no effect

  • Deleting App data temp dir - no effect

  • Forcing password update - no effect, actually made it worse.

It keeps prompting me to log in with the wrong username over and over. I'm on Win10-64Bit, using Sourcetree V.3.0.6.

After reading this post on the Atlassian forum, I tried this:

Login with e-mail NOT username see this comment:

Bo Anderson Aug 06, 2017 • edited Jun 20, 2018 EDIT (20 June 2018): Recent changes to Bitbucket authentication has also meant that you must use your email (NOT your username) when logging in. Currently, logging in with your username is still accepted but seems to cause several issues ranging from this repeated login prompt issue to the "too many login attempts" error when pushing.

I've not seen the issue occur for non-Bitbucket accounts.


(29 Aug 2017): The embedded Git has now been updated, alongside the release of Sourcetree 2.1.11.0. After updating SourceTree, go to Tools > Options > Git and click "Update Embedded Git" to get the latest version (at least 2.14.1).


The majority of issues in Git Credential Manager for Windows have been fixed in recent versions. The latest version (1.12.0) released a couple days ago fixed the remaining issues I had with Bitbucket authentication.

The latest Git Credential Manager for Windows is included in the latest Git for Windows. Until Atlassian updates their embedded version, you could install Git for Windows 2.14.0 and within SourceTree, click "Use System Git" in Options.

Kris's solution also works if you only want to update Git Credential Manager for Windows specifically, though does require config changes.

This actually made it much worse, and I am prompted to login for every team member I'm teamed with.

like image 947
DGRFDSGN Avatar asked Oct 11 '18 09:10

DGRFDSGN


People also ask

How do I fix Git always asking for credentials?

Entering Git Username and Password in Remote URL To prevent Git from asking for your username and password, you can enter the login credentials in the URL as shown. The main drawback of this method that your username and password will be saved in the command in the Shell history file.

How do I add credentials to bitbucket credential Manager?

Go to Control Panel - Credential Manager - Manage Windows Credentials. Find the credentials for @bitbucket.org. Choose "Edit" and change the password for them to the app password.

How to uninstall Sourcetree from Atlassian?

You go to Tools > Options. Choose Git tab, and then choose Embeded in Git version which will tell you the path to their local datas. Mine is "C:\Users\as\AppData\Local\Atlassian". Git Local path And then you need to delete all the folder in the Atlassian and then uninstall SourceTree.

Why Sourcetree can't authorize my GitHub account?

I found out that the reason why SourceTree cannot authorize our GitHub account is that source tree is using the old git version so that it doesn't authorize our account through web but through its own application which is not permitted by Git. Git Notification

How to remove Git credentials from Sourcetree?

Close SourceTree. Open Windows own "Credential Manager". Click "Windows Credentials". Remove all git or SourceTree related credentials (everything starting with "git:" or something similar to "source-tree-rest:" (don't have this one anymore to look it up)). Start SourceTree and reenter the correct passwords of your accounts when prompted.

What is the latest version of Git Credential Manager for Windows?

The majority of issues in Git Credential Manager for Windows have been fixed in recent versions. The latest version (1.12.0) released a couple days ago fixed the remaining issues I had with Bitbucket authentication. The latest Git Credential Manager for Windows is included in the latest Git for Windows.


1 Answers

Using SourceTree 3.4.8 installed on a clean Windows 11 in a virtual machine, I get the credential helper selection dialog.

I found out that selecting "manager-core" from the list and checking always use was the solution. If the popup comes again, selecting the second option "manager-core" was definitive. I don't know why there are several options with the same name, but the second one was the solution.

Also since I was cloning a repository (with https) from bitbucket, I also had to connect to my account in Tools > Options > Authentication > Add > select HTTPS and OAuth, Refresh OAuth Token.

like image 84
prossel Avatar answered Oct 10 '22 09:10

prossel