3

I was trying to get the Google Fuchsia source code, but I keep running into a bunch of these errors:

ERROR: 'git fetch -p origin' failed:
stdout:
stderr:
fatal: unable to access 'https://fuchsia.googlesource.com/third_party/github.com/google/cppdap/':
gnutls_handshake() failed: The TLS connection was non-properly terminated.
command fail error: exit status 128

As a result, the download never fully finishes, and I have an incomplete clone of the Fuchsia repo.

I know that my Git installation is fine because I can access GitHub repos over https just fine (I do it regularly).

I'm on WSL2 (Ubuntu 20.04 LTS).

How can I fix this error?

wermos
  • 123
  • 1
  • 4
  • 9

4 Answers4

8

I disable the sslVerify in Ubuntu. And try to clone git. It works.

git config --global http.sslVerify false
Zgpeace
  • 3,927
  • 33
  • 31
0

In case you still got this error , first of all I suggest to verify the current valid url from the docs

curl -s "https://fuchsia.googlesource.com/fuchsia/+/HEAD/scripts/bootstrap?format=TEXT" | base64 --decode | bash

Then try to force ipv4 with --ipv4 or update curl as described in this answer

apt-get update
apt-get install curl
Stefano Sansone
  • 2,377
  • 7
  • 20
  • 39
0

you can try

sudo git clean -i

that solved my problem for error :

git pull --tags origin main fatal: unable to access 'https:_git_repo_i_cant_reach _': gnutls_handshake() failed: Error in the pull function.

0

In my case the issue was the incorrect value of https proxy variable. The https proxy variable(https_proxy) was using https, where it should have used http.

# WRONG:
https_proxy=https://<proxy-url>

# CORRECT
https_proxy=http://<proxy-url>
Loner
  • 166
  • 1
  • 4
  • 10