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

proxy.golang.org: downloading 1.0.3 while asking for 1.0.4 #41273

Closed
bukowa opened this issue Sep 8, 2020 · 8 comments
Closed

proxy.golang.org: downloading 1.0.3 while asking for 1.0.4 #41273

bukowa opened this issue Sep 8, 2020 · 8 comments
Labels
FrozenDueToAge modules 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.
Milestone

Comments

@bukowa
Copy link

bukowa commented Sep 8, 2020

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

$ go version
go version go1.15 windows/amd64

Does this issue reproduce with the latest release?

Yes.

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

go env Output
$ go env
set GO111MODULE=on
set GOARCH=amd64
set GOBIN=
set GOCACHE=cut...\go-build
set GOENV=cut...\go\env
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GOMODCACHE=cut...\go\pkg\mod
set GOOS=windows
set GOPATH=cut...\go
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=cut...:\Go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=cut...\pkg\tool\windows_amd64
set GCCGO=gccgo
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=cut...\lib\go.mod
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=...cut\go-build712448510=/tmp/go-build -gno-record-gcc-switches

What did you do?

go get -u github.com/bukforks/cobra@v1.0.4

What did you expect to see?

What did you see instead?

go: github.com/bukforks/cobra@v1.0.3/go.mod: verifying module: github.com/bukforks/cobra@v1.0.3/go.mod: reading https://sum.golang.org/lookup/github.com/bukforks/cobra@v1.0.3: 410 Gone
        server response: not found: github.com/bukforks/cobra@v1.0.3: invalid version: unknown revision v1.0.3
@tpaschalis
Copy link
Contributor

Hello!

On your repo, I see that both 1.0.3 and 1.0.4 point to the same commit 43fd3c3, with less than 10 minutes between releasing them and opening your issue, so it might have been an issue with caching? When did you run the above command?

As https://sum.golang.org/ states

new versions may not show up right away. If you want new code to be immediately available in the mirror, then first make sure there is a semantically versioned tag for this revision in the underlying source repository. Then explicitly request that version via go get module@version.

On my end, it seems to be working correctly now

$ mkdir tmpdir
$ cd tmpdir
$ go mod init tmp
go get -u github.com/bukforks/cobra@v1.0.4
go: downloading github.com/bukforks/cobra v1.0.4
go: downloading github.com/inconshreveable/mousetrap v1.0.0
go: downloading github.com/spf13/pflag v1.0.5

Finally, I feel that following the provided template when filling the issue will provide more information that will help understand and resolve the issue in a clearer way in the future!

@bukowa
Copy link
Author

bukowa commented Sep 8, 2020

Hello thanks a lot for your assistance. I just updated the issue to match the template. It is not the first time i have problems with go mod caching. I expected that releasing new package would instantly be available - as it really is.

@tpaschalis
Copy link
Contributor

tpaschalis commented Sep 8, 2020

You're welcome! As https://sum.golang.org/ states, the cache has a quite short TTL, so while not immediate, it should be available very soon.

After one minute for caches to expire, the go command will see that tagged version

You can use go list -m --versions github.com/bukforks/cobra to see the available versions as they're picked up.

Would you like to try and reproduce the behavior? I think that the two tags pointing to the same commit might have something to do with what you observed.

@andybons
Copy link
Member

andybons commented Sep 8, 2020

@bcmills

@andybons andybons changed the title downloading 1.0.3 while asking for 1.0.4 proxy.golang.org: downloading 1.0.3 while asking for 1.0.4 Sep 8, 2020
@andybons andybons added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Sep 8, 2020
@andybons andybons added this to the Unplanned milestone Sep 8, 2020
@bcmills
Copy link
Contributor

bcmills commented Sep 8, 2020

What was your initial go.mod state? This looks superficially similar to #37438 (see #37438 (comment) in particular).

Does the error still reproduce if you run go env -w GOPROXY=direct before the go get command? (Be sure to run go env -u GOPROXY afterward to reset your go command defaults.)

@bcmills bcmills added modules WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. labels Sep 8, 2020
@bukowa
Copy link
Author

bukowa commented Sep 8, 2020

What was your initial go.mod state?

I am pretty sure there was github.com/bukforks/cobra@v1.0.3.

@bcmills
Copy link
Contributor

bcmills commented Sep 9, 2020

@bukowa, you'll need to provide more specific steps to reproduce. Here's what I'm seeing so far:

example.com$ go version
go version go1.15.1 linux/amd64

example.com$ go mod init example.com
go: creating new go.mod: module example.com

example.com$ go get -d github.com/bukforks/cobra@v1.0.3
go: downloading github.com/bukforks/cobra v1.0.3
go: downloading github.com/inconshreveable/mousetrap v1.0.0
go: downloading github.com/spf13/pflag v1.0.5

example.com$ cat go.mod
module example.com

go 1.15

require github.com/bukforks/cobra v1.0.3 // indirect

example.com$ go get -u github.com/bukforks/cobra@v1.0.4
go: downloading github.com/bukforks/cobra v1.0.4

example.com$ cat go.mod
module example.com

go 1.15

require github.com/bukforks/cobra v1.0.4 // indirect

example.com$ go list -m all
example.com
github.com/bukforks/cobra v1.0.4
github.com/cpuguy83/go-md2man/v2 v2.0.0
github.com/inconshreveable/mousetrap v1.0.0
github.com/pmezard/go-difflib v1.0.0
github.com/russross/blackfriday/v2 v2.0.1
github.com/shurcooL/sanitized_anchor_name v1.0.0
github.com/spf13/pflag v1.0.5
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405
gopkg.in/yaml.v2 v2.3.0

@bcmills bcmills added WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. and removed WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. labels Sep 9, 2020
@gopherbot
Copy link

Timed out in state WaitingForInfo. Closing.

(I am just a bot, though. Please speak up if this is a mistake or you have the requested information.)

@golang golang locked and limited conversation to collaborators Oct 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge modules 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