What would stop SourceTree-GUI from fetching/pushing if command line works (with ssh)?

I've got keys configured on the command line that I bring up from the "Terminal" button on SourceTree, but when I try to fetch/push from the SourceTree GUI, I get the following:

git -c diff.mnemonicprefix=false -c core.quotepath=false fetch origin
Access denied
...
FATAL ERROR: Server sent disconnect message
type 2 (protocol error):
"Too many authentication failures for git"
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.

This is via ssh.

What would the GUI be doing with the same repo that's different than the command line?

TIA.

EDIT: Tried starting over, pulling from the existing repo I've set up from the Terminal rather than pushing a new repo to the server.

Unfortunately, it asks me for a password when I believe it's supposed to ask me for the key.  The only strange thing I haven't seen before is that the username for this repo is in the format `ssh://git@repo.server.com:MyLogin/repo_name.git`

I haven't seen a login name presented in the "port" location before.

But I'd still think that the key request should come up.

image2014-10-21 9:13:31.png

The result is...

image2014-10-21 9:18:46.png

2 answers

There is an option in Tools\Options\General called "Check default remotes every N minutes". This causes fetches in the background. If it is on, switch it off.

I'm a little confused. How would background fetches throw off an explicit push? For what it's worth, I turned that off, then clicked "fetch". Same error as above. Clicking "Terminal", then `git fetch`, then typing in my passphrase from the command line still works.

I read your question again. I think the problem is not with things being parallel, but that SourceTree remembers incorrect credentials. You can edit them via Repository\Repository settings in the menu.

Tried starting from scratch and cloning the repo I set up; edits above. /shrug

The structure of the URL is definitely wrong. How did you end up with that? (If you want to add an existing clone for SourceTree to use, you are on the wrong tab, you should use the "Add working copy" tab instead of the "Clone repo" tab.)

With the tab, I was trying for a "clean repo install", so was cloning "from scratch". Looks like the answer was that Pageant wasn't installed. I thought SourceTree did that for me, but apparently not. ? The URL (which came from an on-network install of GiLab) does work, strangely enough.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published May 30, 2018 in Sourcetree

Tip from the team: configuring Git or Mercurial in Sourcetree

Supported Platforms macOS Windows To make using Sourcetree as simple yet powerful as possible we embed (bundle) dependencies such as Git, Git LFS, and Mercurial. We strive to keep these...

433 views 0 1
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