Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Is my cloning stuck or is it just taking a long time?

Luca Wistendahl May 19, 2017

I'm very new to git and I've been cloning a repo from BitBucket cloud in SourceTree to my local machine for roughly an hour now. My internet connection is average and so I'd usually chalk this up to a large repo (I don't have access to check the repo size in BitBucket but I'm cloning an organization's entire website, so I assume it's quite large).

However, the loading bar for the cloning process is full, yet the the output is stuck on "cloning into '<path to repo>'. . ."

Apparently there's no way to accurately check the progress of a clone, but this seems like an abnormally long time. Does this sound like the cloning is stuck or has encountered an error somewhere?

 

EDIT: Spelling

8 answers

1 accepted

3 votes
Answer accepted
Luca Wistendahl May 19, 2017

Apparently it was an issue with SSH. After about 2.5 hours the clone failed and I tried again using HTTPS. It worked fine.

Ahmedur Rahman Shovon
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 11, 2018

Hi Luca,
Same issue here. Could you fix it later?

Like abdellatif.benhamou-njc likes this
Luca Wistendahl April 12, 2018

Hello Ahmedur,

As I mentioned above, all I had to do was use HTTPS and the clone was successful.

Unfortunately I don't remember any more of the details of this issue.

Best of luck!

Like # people like this
reynergiovanni
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 16, 2018

hi Luca, how did you choose between HTTP and HTTPS? 

Bruce
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 16, 2018

i think when you set up your profile

Like kooliatef likes this
Prabakaran Muthusamy
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 24, 2022

is any solutions for SSH method?

Like TheKingArthas likes this
TheKingArthas May 7, 2022

@Prabakaran Muthusamy please check my answer below

Like Anshul Shukla likes this
8 votes
TheKingArthas May 7, 2022

I had exactly the same issue on my Mac using SourceTree and a GitHub account.

This is how I solved it:

  1. Open your terminal (CMD + spacebar, type terminal, press enter).
  2. There clone any repo you want using the SSH path.
    i.e.: git clone git@github.com:MyRepoPath.git
  3. You will receive a message similar to this:
    The authenticity of host 'github.com (xxx.xxx.xxx.xxx)' can't be established.
    ###### key fingerprint is SHA256:******************
    This key is not known by any other names
    Are you sure you want to continue connecting (yes/no/[fingerprint])
  4. Type yes and press enter.
  5. The repo should successfully be cloned.
  6. Come back to SourceTree and try to clone any other repo. It should work as well. 

 

Hope it helps! :)

Matthew Bennett
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 6, 2022

Thanks, this got me 99% of the way to fixing my stuck clone job in source tree issue. There was just one additional step I had to take. 

After running the git clone command in terminal, an RSA key was added for bitbucket.org inside my known_host file. The problem was is that it appended the line at the very end of an existing RSA key for a different host. I had to break the 'bitbucket.org ssh-rsa' to it's own line and boom source tree could properly parse the known_hosts file and no longer get's stuck when cloning repos using ssh keys. 

Thanks again! 

qi ren
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 9, 2022

This works perfectly, thanks!

7 votes
Marco Del Valle December 14, 2018

I tried both SSH and HTTPS, and they both seemed to take an eternity. Then I tried cloning with Git Bash (a text-command tool), and it showed progress was slow but steady.

The problem is that SourceTree's progress bar is completely useless, since it doesn't actually show progress. Additionally, the "Show full output" checkbox also does not show full output. So it's impossible to know if anything is happening. I found that using a command-line tool gives you a lot more information than SourceTree's GUI:

 

Screenshot2.jpg

therightstuff February 21, 2020

this. also, i'm using bitbucket so i don't know if that's related, but the fact that it works nicely from the terminal indicates a bug on the sourcetree side

Hardik Lathigara
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 10, 2020

I could clone from URL in sourcetree successfully for a smaller git repo but when I tried same for a big repo then it got stuck forever.

Like # people like this
2 votes
everettgriffiths
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 15, 2019

This definitely seems to be a problem with Bitbucket's SSH implementation.  I have been able to make SSH connections and do clones of Github repositories using SSH URLs.  As soon as I did a clone of the HTTPS variant, the BitBucket variant worked.  100% this is something broken with Bitbucket.  Now with Gitlab or Github offering private repos, it may not be work keeping code in Bitbucket with fundamental problems like this.

1 vote
Smart Coder
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 29, 2019

I had to use Tortoise Git to see the progress in byte transfer to know whether actually something is happening when cloning.

0 votes
Saurabh Kulkarni
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 3, 2022

Finally solved for me. I installed and opened the GitHub extension then signed in, then it asked for the browser authentication. after that, I ran the command again, and it pulled the repo into local. 

0 votes
sonny
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 17, 2022

I was getting stuck at "Updating files: 100%" when cloning a git repo on Windows.

I changed to use System git instead of Embedded git, and that workaround fixed it for me.

See `Sourcetree -> Options -> Git -> Git Version`

0 votes
Arif Z March 3, 2021

In my case, I realized that using different Internet connection to the one when I first cloned it using SSH caused the problem so maybe try to check which Internet connection you used

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events