It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Error while adding SSH key with GitHub account it says Upload Failed

Hello everyone I'm new to using SourceTree and I need to use the stash functionality basically for my task at work ( I know it can be done with git terminal as well ) 

Whenever I set up my GitHub account and with SSH protocol and my SSH key it says 

```
Upload failed

 

There was a problem adding your new SSH key to your GitHub account. Please add this manually via their website.
```

Now I have also again configured my system's Macbook pro's SSH key to my GitHub account again but the same error appears. 

Any help/information/guidance is appreciated.

5 answers

Can confirm this worked for me. New install using an old (sourcetree-generated) key.

Hello, I am having this exact error with source tree 4.07.

I have tried all the recommended fixes and I cannot use source tree to access github at all.  

I am running the latest install of Mac Catalina, and I have XCode setup to work with personal tokens from github, all access to github is managed through ssh keys per githubs recommendation as part of their security enhancements.

 

the only git client that doesn't work with github is now sourcetree.  

Again, I have tried all the recommended fixes and I am still stuck with this error

I am getting this error right now. I have source tree connected to a different GH account and everything works fine. I checked the .pub files are different and the config file is edited properly in my .ssh folder. not sure what else to do. 

any ideas @bgannin ? Even when i add the key manually it still wont load my remotes in from that GH project. Super odd

bgannin Atlassian Team Apr 02, 2019

When you run the command "ssh-add -l" does it show all your key(s) loaded into the agent?

Hey @bgannin - thanks for replying. Yeah all my keys are there

I am also getting this error, but everything else related to Github integration seems to be working. Can't push or pull, basically can't do any work with Sourcetree and Github until this is fixed. Bummer!

1 vote
bgannin Atlassian Team Nov 19, 2018

Hi Divyesh,

Our apologies for the hiccup. Can you check in Console for any logs from Sourcetree that are printed when this error occurs. Alternatively you can you follow the steps in this article to help debug a bit further hopefully. 

Brian Ganninger
Senior Mac Developer, Sourcetree

no there was no logs available in the console. And after few try and errors I was  finally able to set it up with HTTPS and the software itself needs to get restarted before any repos gets loaded so yeah that way now its all set up and working.

Thank you for the response. :)

I keep getting the same error, when I turned debugging on, this log keeps appearing:

2019-03-11 17:27:25 +0000 (e) Error uploading key. Server returned - {"message":"Not Found","documentation_url":"https://developer.github.com/v3/users/keys/#create-a-public-key"}

It was working fine, all my keys are loaded and Sourctree with GitHub has stopped working, same error!

Same issue for me. 

For me worked this:

  1. I removed all my added SSH keys on github.com/settings/keys
  2. Removed all credentials and access keys in Keychain Access on Mac OS
  3. Reauthorized GitHub account in Source Tree Settings -> Accounts

Yes, this is very brute force solution, but I was updated to a newly MacBook and didn't transfer data (including SSH keys) from old MacBook. So for me saving old SSH keys was optional.

N.B.! Do not use this solution if you are using your existing SSH keys on other machines.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Sourcetree

Sourcetree for Windows - CVE-2019-11582 - Remote Code Execution vulnerability

A vulnerability has been published today in regards to Sourcetree for Windows.  The goal of this article is to give you a summary of information we have gathered from Atlassian Community as a st...

4,910 views 0 12
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you