Permission Denied (publickey)

Hi,

I'm receiving this error in Sourctree:

Permission denied (publickey).
fatal: The remote end hung up unexpectedly
Unable to fetch in submodule path 'YBAudioFramework'

I believe sourcetree prompted me for a publickey access at one point when I was neither pulling nor pushing, and I clicked deny out of principle. Now I'm being punished for that :) How can I give sourcetree access again? I tried going through keychain access and also removing the hostusername map from Library/Application Support/Sourcetree

Any other ideas?

1 answer

1 accepted

Just FYI, the time SourceTree prompted you was because by default it does a periodic background fetch in order to be able to show you the ahead/behind markers relatively up to date without manual action. You can disable this in Preferences if you like. As for the error, are you certain your key works elsewhere? SourceTree just goes via ssh here so it's behaviour should reflect the command line too. The permission prompt is, IIRC, just to allow the app to use your keychain entry to unlock the key if it's pass phrase protected. I might be misremembering that since I haven't had to grant it in a hole, but I don't believe there's a 'Always deny' option, only allow, deny and always allow. It's possible the key has been unlocked in your session (Mac comes with ssh- agent effectively running automatically so you'll only have to type the pass phrase once) and the problem is actually a genuine key rejection.

For some reason my key was working with another repo but not this one. I created a new key and now everything is working, so you were right it was a key issue, not a sourcetree issue.

Thanks!

Suggest an answer

Log in or Join to answer
Community showcase
Brian Ganninger
Published Jan 23, 2018 in Sourcetree

Tip from the team: workflow and keyboard shortcuts

Supported Platforms macOS Sourcetree has a lot to offer and, like many developer tools, finding and using it all can be a challenge, especially for a new user. Everyone might not love ...

261 views 0 3
Read article

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot