I recently tried to set up my dev environment on a new macbook.
I first tried to authenticate using HTTPS with Bitbucket but even after verifying/resetting my password multiple times, I can just not login, I just get a very random error message:
Could not authorize request with the available token. Please re-authenticate.
To login, I have tried adding my Bitbucket account through 'preferences/accounts'
Screenshot 2017-01-12 15.15.15.png
After supplying my credentials it sometimes briefly loads my avatar correctly, like it does for GitHub but upon loading repository browser, it instantly unloads the avatar and throws the error above:
Screenshot 2017-01-12 15.19.32.png
This is getting very annoying, very quickly...
Moreover, even though I have correctly generated an SSH key pair and added the public keys to my GitHub and Bitbucket accounts, the Sourcetree account UI refuses to 'see' or let me add my keys... it insists on generating new ones. Why is that?
Screenshot 2017-01-12 15.22.45.png
Screenshot 2017-01-12 15.22.54.png
Like this, Sourcetree is effectively useless ...
EDIT
The above issue presents itself when trying HTTPS authentication in combination with OAuth. If instead 'basic' authentication is chosen, repo browser seems to load remotes correctly. However, occasionally I still seem to get logged out.
Hi everybody,
I'd like to start by saying we hear your feedback and understand your frustration. We know how serious this is and apologize for the pain caused by these bugs.
We're a small but dedicated team in Atlassian doing our best to balance everyone's needs. When something like this happens we are keenly aware of how we failed you and know that we need to, and will, do better. Now let’s dig into some of the details and provide clarity around issues for this topic.
Several moving parts affect the authentication processes in Sourcetree for macOS:
• OAuth tokens that have differing expirations and requirements per hosting service
• Classic HTTPS username/password challenges
• Two factor authentication
• SSH keys (user managed or ST managed)
The following external changes also had an impact:
• macOS revising how SSH keys are loaded and managed in 10.12 and 10.13 (details)
• GitHub deprecating and disabling 'weaker' TLS encryption (details)
That complexity is our problem to solve though and you count on us to do it while delivering a rock solid experience, period.
To make tracking down issues less painful we've opened up our internal auth logging via the new Debug menu in 2.7.2. We are dedicated to improving this area, with fixes present in every release since we first started expanding the authentication options. Each sprint includes dedicated time to review and investigate any new authentication reports with test builds often privately shared with those affected.
Filing a ticket (https://jira.atlassian.com/browse/SRCTREE) is the single best way to help out. We review every ticket for how it impacts Sourctree, determine if it’s an existing or duplicate issue, and then follow up if we need more information or clarity.
Beta content, especially bug reporting, is not discussed or triaged on Community because this forum is for public releases - anything related to betas should be discussed on the "Trusted Testers" mailing list (https://groups.google.com/forum/#!forum/atlassian-sourcetree-beta) and/or tickets per the introductory message.
We genuinely want your help when these issues arise. Please vote or comment on an existing ticket; if there isn't one, open a new ticket with as much detail as you can provide. This will help us attack the right problems as fast as we can.
These are the primary tickets we're tracking for future updates:
• SRCTREE-5368 missing uuid (fix deploying in 2.7.2 beta 4 today)
• SRCTREE-4544 multiple prompts for SSH Keychain password
• SRCTREE-5372 multiple password prompts with HTTPS
Thank you for your feedback, patience, and tickets - we strive to make our apps better every day.
Brian Ganninger
Senior Mac Developer, Sourcetree
Thanks for your response. One note - 5372 either doesn't exist or the general public doesn't have permission to view it.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Brian . Is this solved? I'm stilling getting errors. See: https://community.atlassian.com/t5/Sourcetree-questions/Getting-quot-Could-not-authorize-request-with-the-available/qaq-p/708633#U915415
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi all,
The addition of OAuth was a fundamental architecture change for SourceTree on macOS and unfortunately there have been a number issues centered around how tokens are stored and accessed in the keychain that we've spent a lot of time investigating for the next update (2.5.2). That release is available here as OSX_Beta_Latest.zip currently with a refresh coming tomorrow (you can sign up for the trusted_testers mailing list to be notified of updates.) Full details: 2.5.2 Release Notes
We greatly appreciate our community's patience as we deal with these growing pains and varying implementation details such as hourly token timeouts or newly introduced rate limiting. Once 2.5.2 is generally available if you're still encountering problems we'd ask that you reach out either via a ticket on JIRA or Atlassian Support, depending on your preferences. Rest assured, we're reading your feedback in all channels and striving to make the product better with each release.
Brian Ganninger
Senior Mac Developer, SourceTree
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The new build, 2.5.2 (109), is now available as a beta.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Brian, I've tried the beta version (2.5.2), still doesn't work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please file a ticket on JIRA (see previous posts) and we'll follow up on debugging details. Thanks for your patience.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So the issue really does seem to be that if you have the same username on your github and bitbucket accounts, you cannot authorise with bitbucket on a macintosh device. I had this issue until i changed by usernames on both accounts, and I seem to be able to pull down code now.
My desktop PC and Sourcetree works fine, no issues. Really bizarre problem that Atlassian really needs to look into!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Almost a year after this and still things don’t work. Come on guys... get on it and address it properly.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Changing my account protocol from HTTPS to SSH in Preferences > Accounts solved this problem for me.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for this, I was on SSH and changed it to HTTPS and managed to login. Then I changed it back to SSH and it works fine.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am having the exact same issue.
os:macOS sierra 10.12.3
SourceTree 2.4
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
when i change the username , everything will be OK
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried as you said, before i had the same usernames for my Github and Bitbucket accounts. Then i changed the username of my Bitbucket account and everything works now :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am having a similar issue, but for me it's with github. I was having a similar issue connecting to bitbucket, but was able to get around it by allowing SourceTree to create a new key.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm on version 2.7.3 (169) and was trying to revert from OAuth to Basic auth and the dialog hides the password field so you can't even enter your password. I got around this by tabbing from the username field to the hidden password field and pasting my password.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Is this on Basic auth + ssh configuration for account?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ugh. This is freaking annoying. I'm going to have to abandon SourceTree.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm evaluating Git Tower and so far it's pretty good. It's not free though.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This is maddening. It was working without any changes to SourceTree or my bitbucket account. And then it just stopped working. I can't push or pull via SourceTree. Sure, I can use the command line, but I like the UI. I'm not sure Atlassian cares if people abandon SourceTree because this problem continually pops up just out of the blue, people complain, and nothing gets done other than to tell people to jump through hoops to fix a problem they can't seem to figure out.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You said above that downgrading to 2.6.3 fixed it for you. Well, I was on 2.6.3 when it started happening. So, I removed it completely from my system and installed the most current version (2.7.1) and have the same problem. Maybe only downgrades from the version you are using fixes it. LOL.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Come to think of it, I think I was on 2.6.3 when I started having problems. So I did the same thing, completely removed it from my computer, installed the latest, and the problem was still there. Then I downgraded to 2.6.3 and it started working again. My problems started the day that they had the outage. I was thinking that maybe that played a part in it. Not sure if it matters but I'm on a Mac.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I still have the same issue with 2.7.3, OAuth / SSH never works. Only Basic HTTPS works but it always asks me for password every single time even if the store password option is still selected.
But SSH mode works nicely with Github account, not sure why doesn't work well with Bitbucket when source tree is one of their product 😕
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please provide details on the errors you see and the account configuration to help you in this regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I followed the instructions from here, still it fails and keeps asking me to login using SSO and even after it fails. My username is `manojdcoder`
But with Github, I followed the same and it worked like charm.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you make sure your repository's remote URL is also SSH? It could complain if its not. You can right click on the repo listed in the repo browser and convert it to SSH if needed.
As as second step, I would recommend you to remove the account and add it again to make sure the right credentials are stored in keychain and it doesn't use a stale one.
Along with that, please check if the ssh-agent has your keys loaded. If not, please add them to the agent.
Run below commands in terminal to do so,
To check if keys are loaded:
ssh-add -l
To add keys to agent:
ssh-add <path_to_key>
more like,
ssh-add ~/.ssh/id_rsa
Key in the passphrase used while generating the ssh key and you should be good to go.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm not sure which repo URL I used, will try once again to with SSH and update here.
But at least I expected it to list all my repos, but it always thrown me errors. I'm sure the keys stored were right ones.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Gotcha! You should remove the account and add it back to see the repos listed. Please revert back if you end up seeing errors.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It's always the same errors. Besides even if I use basic username / password authentication, it still asks me password every time no matter how many times I check the option to save in keychain.
I'm really wondering why an Atlassian's product should work really well with Github but why not with it's own Bitbucket. If you think I'm missing something, kindly share a step by step video / image tutorial for Mac with latest SourceTree. I have followed this guide 100 times already, so kindly do not paste the same.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you add some screenshots of the account setup and paste the output of below command?
ssh-add -l
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It simply says "The agent has no identities." Still Github account worked, the steps followed were exactly same.
Sadly I moved to GitKraken app after being with SourceTree for at least 4+ years. I liked SourceTree, it used to be simple, easy and clean. With GitKraken the steps to add Bitbucket SSH was exactly same and it worked on first try.
I will definitely be happy to get back to SourceTree once I know these hurdles are resolved. Thank you for your support.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That explains it. As I mentioned earlier above, the ssh agent on your Mac doesn't have the key loaded. You need to load the key manually by running below command. Without which, I believe you wouldn't be able to use it even with command line.
ssh-add <path_to_key>
The reason why this happens is because of the changes Apple made with OpenSSH on the macOS. You can read more about it here.
Alternately, you can switch to using https with OAuth if you feel ssh is a hurdle.
We are working to resolve this problem for our users in a grateful way. But, that would take some time given the team size of Sourcetree and all the things that take a slightly higher priority.
Should you need help getting the setup right, please feel free to reach out to me and I can Skype to help you with that. We would be glad to have you back to using Sourcetree.
Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
1. I am not sure why this didn't work for you. But, we know of some issues in 2.7.3 which we have fixed in 2.7.4. Feel free to try it out by downloading the new build here - https://bitbucket.org/atlassianlabs/sourcetree-betas/downloads/OSX_Latest.zip. Again, I recommend you remove your account and add it again. You can enable debug logs and send me when you do that. Navigate to Preference window -> Advanced tab and enable "Show Debug Menu" checkbox. From the new menu that gets displayed at the end of the main menu, Enable Auth Logging and Select Debug under Log Level. There are options to locate the log folder.
2. Please provide a screenshot of your account config in Sourcetree and a screenshot of the repo you've cloned ( I need to confirm the protocol used in the repo).
3. Sourcetree uses either embedded git binary or your system git to run everything for you. We try to keep things as native as possible. If you can work with command line and your ssh works, it works with Sourcetree. On the other hand, other applications use various libraries, third party dependancies to run git and support git. You may want to check if there are multiple ssh agents running on your machine.
Terminal should be the best place to confirm the ssh setup for git and Sourcetree.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The issue is still there, i'm having the same problem.
I feel frustrated. my sourcetree version is 2.7.1.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks, that worked for me too. I'm done upgrading Sourctree. Too many times I've been burned by bad updates. If it works, don't upgrade.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi All, has anyone solve this issue? i'm having the same problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
As a workaround, when I was awaiting notification from our security team that my access was granted ...
I logged in to SourceTree with my google account.
Then I logged into my repo from within Sourcetree, and no issues.
I *was* having issues with direct bitbucket repo creds against sourcetree.
Since the initial success with my gmail to get into SourceTree, I am using my internal account as desired for all logins.
hope this helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks, downgrading to 2.6.3 worked for me too. I'm done upgrading Sourctree. Too many times I've been burned by bad updates. If it works, don't upgrade.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have the same exact issue.
Has this been fixed yet?
I've reinstalled Sourcetree, cleared all caches, keychain credentials and am still unable to access my remote gits.
My error is " The operation couldn’t be completed. (com.google.HTTPStatus error 401.)"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you confirm the version of Sourcetree you have installed now?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This happens even with the most up to date versions of Sourcetree (It auto updates rather frequently): currently 2.7 (152)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same issue. Just got my new mac book pro, installed latest version of source tree 2.7 (152), and no dice.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same here. SourceTree 2.7
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Exactly the same problem, it's very frustrating.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
One of the latest builds for macOS seems to resolve the matter finally:
Actual version no is 2.5.2, build 111
Knock on wood...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, I've tried 2.5.3c and 2.6.3a on MacOS 10.11.6 (El Capitan) - and both I'm having issues connecting to bitbucket. Same errors reported by this user both for the oAuth as well as basic authentication. I'm able to connect using the preferences/accounts - but when I tried to refresh the repo I get the errors.
Appreciate any help!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, Can you please make sure the protocol for the account and your repo clone/remote URL are same?
If account is ssh, remote URL should also be ssh and likewise with https.
I would recommend using the latest version 2.7 (142) for your work.
Thanks,
Manjunath
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am having the same issue... I cannot login to Bitbucket in Sourcetree to update my remote repositories. I am using 2.7 on MacOS High Sierra. I checked that the protocol is the same. I tried with OAuth and with the Basic Auth Type. Nothing seems to work. I can login just fine on BitBucket Cloud though, and double checked my username and password. Nothing works... Any help is appreciated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you describe what is happening when you try to login and include any error messages, screenshots that might help us help you with this?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I was getting the same errors as Paul (post on Mar 07,2017). However, I just managed to fix it by changing my username on Bitbucket, by adding a few more characters to it, and then updating it in SourceTree. I found this suggestion in one of the replies above. Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Any body solved this issue without changing usernames?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You might havre mentioned that you need to download an early build for things to work.
The officially available 2.5.2 (105) still has issues.
The build that actually fixes things is 2.5.2 (111)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I still have 2.5.2 (105), but it's good to know 2.5.2 (111) fix the issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Well in 105, the issue definitely was not resolved. But anyway...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same issue. It's getting extremely annoying...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same issue started happening suddenly for no apparent reason.
"Could not authorize request with the available token. Please re-authenticate."
And am CONSTANTLY receiving prompts to enter BitBucket password, even when there are several prompts already displayed.
SourceTree v2.5 (104)
MacOS v10.12.4 (16E195)
Issue persists after performing the following:
My BitBucket and GitHub usernames are the same, but I'm not even trying to add GitHub at the moment.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That's what happens on mine as well.
It seems related to High Sierra Mac OsX, and the current version of Sourcetree as of January 2018.
I fixed mine by changing my username on Bitbucket, but I still get intermittent issues around auth and saving my password to keychain.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same issue here. Fix this please!!! SourceTree 2.4.1 MacOS sierra.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It's been two months and I still can't connect
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried as you said, before i had the same usernames for my Github and Bitbucket accounts. Then i changed the username of my Bitbucket account and everything works now :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Identical issue here too.
If I am oauth/SSH I get:
Could not authorize request with the available token. Please re-authenticate.
If I am to basic/SSH I get:
The operation couldn’t be completed. (com.google.HTTPStatus error 401.)
If I am oauth/HTTPS I get:
Could not authorize request with the available token. Please re-authenticate.
If I am basic/HTTPS I get signed in, but I have to re-enter my password twice on each pull or push, despite the 'store in keychain' option being set.
Very close to giving up.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This is with BitBucket. GitHub works perfectly for me!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
is your Bitbucket and github account names equal? if so change your Bitbucket account name (just add 2-3 more characters at the end) and retry. i solved my problem just like this.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm also experiencing this issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
same here! I hope there's a fix soon!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same issue, couldn't authenticate to github.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Same here, no solution yet?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.