Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/go: unable to get golang.org/x/... packages #25495

Closed
GonchuB opened this issue May 22, 2018 · 10 comments
Closed

cmd/go: unable to get golang.org/x/... packages #25495

GonchuB opened this issue May 22, 2018 · 10 comments
Labels
FrozenDueToAge WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.

Comments

@GonchuB
Copy link

GonchuB commented May 22, 2018

I am unable to get packages hosted in go.googlesource.com, I can't even clone the repositories by hand, getting the same error.

What version of Go are you using (go version)?

go version go1.10.2 linux/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

GOARCH="amd64"
GOBIN=""
GOCACHE="/home/sanz/.cache/go-build"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/sanz/go"
GORACE=""
GOROOT="/home/linuxbrew/.linuxbrew/Cellar/go/1.10.2/libexec"
GOTMPDIR=""
GOTOOLDIR="/home/linuxbrew/.linuxbrew/Cellar/go/1.10.2/libexec/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc-5"
CXX="g++-5"
CGO_ENABLED="1"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build001979355=/tmp/go-build -gno-record-gcc-switches"

What did you do?

$ go get -u golang.org/x/crypto/bcrypt

What did you expect to see?

I expected to get crypto installed

What did you see instead?

go get -u -v golang.org/x/crypto/bcrypt
Fetching https://golang.org/x/crypto/bcrypt?go-get=1
Parsing meta tags from https://golang.org/x/crypto/bcrypt?go-get=1 (status code 200)
get "golang.org/x/crypto/bcrypt": found meta tag get.metaImport{Prefix:"golang.org/x/crypto", VCS:"git", RepoRoot:"https://go.googlesource.com/crypto"} at https://golang.org/x/crypto/bcrypt?go-get=1
get "golang.org/x/crypto/bcrypt": verifying non-authoritative meta tag
Fetching https://golang.org/x/crypto?go-get=1
Parsing meta tags from https://golang.org/x/crypto?go-get=1 (status code 200)
golang.org/x/crypto (download)
# cd .; git clone https://go.googlesource.com/crypto /home/sanz/go/src/golang.org/x/crypto
Cloning into '/home/sanz/go/src/golang.org/x/crypto'...
fatal: unable to access 'https://go.googlesource.com/crypto/': Unrecognized content encoding type. libcurl understands identity content encodings.
package golang.org/x/crypto/bcrypt: exit status 128
@agnivade
Copy link
Contributor

This seems to be an issue with your system. It is more apparent because you can't even clone the repositories manually. Please upgrade your libcurl version and try again. Also ensure that you don't have any proxy servers incorrectly configured.

@agnivade agnivade added the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label May 22, 2018
@agnivade agnivade changed the title Unable to get golang.org/x/... packages cmd/go: unable to get golang.org/x/... packages May 22, 2018
@GonchuB
Copy link
Author

GonchuB commented May 22, 2018

@agnivade have the latest curl and git versions, no proxies. I can clone git repositories from github, but not from go.googlesource.com:

$ curl --version
curl 7.60.0 (x86_64-pc-linux-gnu) libcurl/7.60.0 OpenSSL/1.0.2o
Release-Date: 2018-05-16
Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp 
Features: AsynchDNS IPv6 Largefile NTLM NTLM_WB SSL TLS-SRP UnixSockets HTTPS-proxy
$ git --version
git version 2.17.0

Other people in my company are getting the same issue since Sunday

@davecheney
Copy link
Contributor

Other people in my company are getting the same issue since Sunday

Does the issue only occur inside your company? You may need to talk to your network administrators and check that they are not filtering your traffic.

@GonchuB
Copy link
Author

GonchuB commented May 22, 2018

@davecheney I am working remotely, we are in different countries/buildings (no vpn, no proxy). I am not filtering my traffic :)

@GonchuB
Copy link
Author

GonchuB commented May 22, 2018

Output of plain curl

$ curl https://golang.org/x/crypto
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta name="go-import" content="golang.org/x/crypto git https://go.googlesource.com/crypto">
<meta name="go-source" content="golang.org/x/crypto https://github.com/golang/crypto/ https://github.com/golang/crypto/tree/master{/dir} https://github.com/golang/crypto/blob/master{/dir}/{file}#L{line}">
<meta http-equiv="refresh" content="0; url=https://godoc.org/golang.org/x/crypto">
</head>
<body>
Nothing to see here; <a href="https://godoc.org/golang.org/x/crypto">move along</a>.
</body>
</html>

@GonchuB GonchuB closed this as completed May 22, 2018
@ysmolski
Copy link
Member

@GonchuB what was the fix for you?

@GonchuB
Copy link
Author

GonchuB commented May 22, 2018

Some keg (using linuxbrew) installed git and curl as a dependency, so those binaries were being used instead of the system ones. Apparently they were not working correctly (it is odd, because they worked correctly with github repos and go packages) but not with go.googlesource ones. Uninstalled git and curl kegs and issue was solved

@ysmolski
Copy link
Member

I am glad to hear that you found the solution!

@agnivade
Copy link
Contributor

Wow, weird indeed.

@the-codetrane
Copy link

@GonchuB Thank you for saving me hours of banging my head against the wall! Just had (and resolved) the same issue.

@golang golang locked and limited conversation to collaborators Jun 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Projects
None yet
Development

No branches or pull requests

6 participants