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: module downloads contain vendor/modules.txt #63395

Open
rsc opened this issue Oct 5, 2023 · 1 comment
Open

cmd/go: module downloads contain vendor/modules.txt #63395

rsc opened this issue Oct 5, 2023 · 1 comment
Assignees
Labels
GoCommand cmd/go modules NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@rsc
Copy link
Contributor

rsc commented Oct 5, 2023

go mod download -json github.com/go-delve/delve@latest
shows a Dir that contains vendor/modules.txt.
None of the other vendor files are present, just modules.txt.

This is probably a bug: we intended for modules to contain
no vendored info at all, but we had to leave files in the root
alone because they might be for a package or command
named vendor (only subdirectories are trimmed).

We should probably update the logic to trim modules.txt
as well, but only when the go.mod has a new enough Go version.

/cc @bcmills

@rsc rsc added the NeedsFix The path to resolution is known, but the work has not been done. label Oct 5, 2023
@rsc rsc added this to the Go1.22 milestone Oct 5, 2023
@dmitshur dmitshur added the GoCommand cmd/go label Oct 6, 2023
@bcmills
Copy link
Contributor

bcmills commented Oct 11, 2023

I think this is another symptom of the known bug described in #31562.

I agree that this is something we can probably fix now that Go 1.21 and above refuse to produce module zips for Go versions that are too new.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GoCommand cmd/go modules NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

5 participants