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

net/http: bundle invocation without -dst is fragile #25285

Closed
FiloSottile opened this issue May 8, 2018 · 5 comments
Closed

net/http: bundle invocation without -dst is fragile #25285

FiloSottile opened this issue May 8, 2018 · 5 comments
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@FiloSottile
Copy link
Contributor

FiloSottile commented May 8, 2018

The bundle invocation in the net/http go:generate for h2 does not have a -dst flag. So it breaks when bundle was not built with the toolchain associated with the target net/http package, as the embedded GOROOT is wrong. When developing the standard library it's fairly common[citation needed] to use a different system compiler to go get binaries, so it's probably worth adding -dst at the next run.

/cc @bradfitz

@FiloSottile FiloSottile added this to the Go1.11 milestone May 8, 2018
@bradfitz
Copy link
Contributor

bradfitz commented May 8, 2018

I'm inclined to say that you're holding it wrong.

That tool has had approximately 1-2 users. Now maybe 1-3. I don't think it's worth the effort changing the tool to be more accommodating to more (uncommon?) configurations.

But if you want to, all yours.

@bradfitz bradfitz modified the milestones: Go1.11, Unreleased May 8, 2018
@bradfitz
Copy link
Contributor

bradfitz commented May 8, 2018

Definitely not a Go 1.11 blocker by any means.

@FiloSottile
Copy link
Contributor Author

The tool already has the feature, this is only here to remember to add -dst net/http next time one of us runs it, as it did not feel worth of its own CL.

@dmitshur dmitshur added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Sep 15, 2020
@dmitshur dmitshur modified the milestones: Unreleased, Backlog Sep 15, 2020
@dmitshur
Copy link
Contributor

dmitshur commented Sep 15, 2020

I don't understand this issue. When the -dst flag is not specified, bundle uses the package in the current working directory. The go generate command always sets the working directory to that of the package which is being generated. So, not specifying -dst flag means to use the net/http package that's being processed. I don't see how it could ever use a different embedded GOROOT.

It's possible there was an issue here in the past, but I don't think there's anything to do here after #32031 is fixed (by CL 189818).

@FiloSottile I suggest we close this unless you think this still needs to be done (if so, please explain).

@FiloSottile
Copy link
Contributor Author

Probably obsoleted, closing.

@golang golang locked and limited conversation to collaborators Sep 29, 2021
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