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

x/vgo: how to list missing modules for imported packages #25162

Closed
dlsniper opened this issue Apr 29, 2018 · 3 comments
Closed

x/vgo: how to list missing modules for imported packages #25162

dlsniper opened this issue Apr 29, 2018 · 3 comments
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@dlsniper
Copy link
Contributor

dlsniper commented Apr 29, 2018

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

go version go1.10.1 windows/amd64 vgo:2018-02-20.1

Does this issue reproduce with the latest release?

Yes.

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

set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\florin\AppData\Local\go-build
set GOEXE=.exe
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=windows
set GOPATH=D:\go
set GOPROXY=
set GORACE=
set GOROOT=C:\Go1.10
set GOTMPDIR=
set GOTOOLDIR=C:\Go1.10\pkg\tool\windows_amd64
set GCCGO=gccgo
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
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 -fmessage-length=0 -fdebug-prefix-map=C:\Users\florin\AppData\Local\Temp\go-build151584538=/tmp/go-build -gno-record-gcc-switches
set VGOMODROOT=

What did you do?

vgo list -m

If possible, provide a recipe for reproducing the error.
https://github.com/dlsniper/vgodemo/tree/9aa4dcefd9a608bf3db6e9cb1b102e508de95b78

What did you expect to see?

I would expect to see that github.com/aws/aws-sdk-go/aws/session or github.com/aws/aws-sdk-go is not a recognized/present module in my project and have a way to add it to go.mod instead.

The only way to get this done currently seems to be running vgo build on the directory, but this means also compiling the application. I would expect to have a way to download missing modules/packages without having to invoke the build command. Maybe I missed it but I can't see anything in help either.

What did you see instead?

Nothing.

Edit:
While it's great that vgo list - m does not resolve packages and its running really fast, so it shouldn't be modified, maybe a standalone command, vgo list - missing, would make it easier to list what packages are missing.

Thank you.

@gopherbot gopherbot added this to the vgo milestone Apr 29, 2018
@bcmills bcmills added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Apr 30, 2018
@bcmills
Copy link
Contributor

bcmills commented Apr 30, 2018

https://research.swtch.com/vgo-tour says “A side effect of running any vgo command is to update go.mod if necessary,” so it's a bit surprising that vgo list doesn't.

@dlsniper dlsniper changed the title x/vgo: list -m does not list imported packages missing from modules x/vgo: how to list missing modules for imported packages May 1, 2018
@rsc
Copy link
Contributor

rsc commented Jul 5, 2018

This is almost certainly fixed now. If not now then by CL 121303.

@gopherbot
Copy link

Change https://golang.org/cl/121303 mentions this issue: cmd/go/internal/vgo: load packages in parallel

@golang golang locked and limited conversation to collaborators Jul 10, 2019
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.
Projects
None yet
Development

No branches or pull requests

4 participants