Skip to content

proxy.golang.org: go mod vendor, go get <package>, etc not working with "unexpected EOF" error #46179

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

Closed
charlielj88 opened this issue May 14, 2021 · 6 comments
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.

Comments

@charlielj88
Copy link

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

$ go version
v1.14

Does this issue reproduce with the latest release?

No

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

go env Output
$ go env
GO111MODULE="on"
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/nexus/.cache/go-build"
GOENV="/home/nexus/.config/go/env"
GOEXE=""
GOFLAGS="-mod=vendor"
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GONOPROXY="bitbucket.global.xxx.com"
GONOSUMDB="bitbucket.global.xxx.com"
GOOS="linux"
GOPATH="/home/nexus/go"
GOPRIVATE="bitbucket.global.xxx.com"
GOPROXY="https://proxy.golang.org"
GOROOT="/usr/local/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/home/nexus/taric-proxy/taric-proxy/go.mod"
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 -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build760853934=/tmp/go-build -gno-record-gcc-switches"

What did you do?

run the commands,
go mod vendor
or
go get -v -x github.com/dgrijalva/jwt-go/@v/v3.2.0+incompatible

What did you expect to see?

(The downloading successful response)

What did you see instead?

go: github.com/dgrijalva/jwt-go@v3.2.0+incompatible: Get "https://proxy.golang.org/github.com/dgrijalva/jwt-go/@v/v3.2.0+incompatible.mod": unexpected EOF

@seankhliao
Copy link
Member

1.14 is no longer supported, does this still happen with a supported release (1.15, 1.16)?
(It is also more likely to a network issue on your end)

@charlielj88
Copy link
Author

charlielj88 commented May 14, 2021

1.14 is no longer supported, does this still happen with a supported release (1.15, 1.16)?
(It is also more likely to a network issue on your end)

I also suspect this may be due to some network issue. However, I could directly open/access the link https://proxy.golang.org/github.com/dgrijalva/jwt-go/@v/v3.2.0+incompatible.mod via browser/using wget in the same environment. Wondering in the backend how the commands "go get"/"go mod" differ from opening the link directly.

I havn't got a chance to switch to 1.15/1.16 to test in the same environment, but definitely will give it a try soon later.

@heschi heschi changed the title go mod vendor, go get <package>, etc not working with "unexpected EOF" error proxy.golang.org: go mod vendor, go get <package>, etc not working with "unexpected EOF" error May 14, 2021
@heschi heschi added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label May 14, 2021
@heschi
Copy link
Contributor

heschi commented May 14, 2021

I suspect you have a proxy configuration that wget and your browser understand but that Go does not.

@charlielj88
Copy link
Author

charlielj88 commented May 14, 2021

I suspect you have a proxy configuration that wget and your browser understand but that Go does not.

Yes I have a proxy configured for web access. From my IDE (VS Code) it should take the same proxy settings (http_proxy/https_proxy) and I trigger the commands from the IDE only. I am not sure why both ways behave differently.

@bcmills bcmills added the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label May 15, 2021
@bcmills
Copy link
Contributor

bcmills commented May 15, 2021

Could this be a proxy configuration issue? It looks superficially similar to #29809. (See especially #29809 (comment).)

@charlielj88
Copy link
Author

Could this be a proxy configuration issue? It looks superficially similar to #29809. (See especially #29809 (comment).)

Thanks a lot! After removed the "https://" from the proxy settings, I am able to connect and download. Have a nice day!

@bcmills bcmills closed this as completed May 15, 2021
@golang golang locked and limited conversation to collaborators May 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Projects
None yet
Development

No branches or pull requests

5 participants