-
Notifications
You must be signed in to change notification settings - Fork 606
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
pprof fails to work with Go modules #611
Comments
This change adds $GOPATH/pkg/mod as a possible base to search from given that Go modules have been the norm since Go1.11 and we are currently at Go1.16/1.17, hence support for Go modules. Fixes google#611
This change adds $GOPATH/pkg/mod as a possible base to search from given that Go modules have been the norm since Go1.11 and we are currently at Go1.16/1.17, hence support for Go modules. Fixes google#611
This change adds $GOPATH/pkg/mod as a possible base to search from given that Go modules have been the norm since Go1.11 and we are currently at Go1.16/1.17, hence support for Go modules. Fixes google#611
This change adds $GOPATH/pkg/mod as a possible base to search from given that Go modules have been the norm since Go1.11 and we are currently at Go1.16/1.17, hence support for Go modules. Fixes google#611
I just hit this bug -- is there any workaround other than implementing this patch to the pprof tool? |
I run into the same problem when downloading the debug info from a remote server: As a short term workaround that seems to have move the needle for me was creating a symlink for the
Now the output displays as expected:
|
Please answer these questions before submitting your issue. Thanks!
What version of pprof are you using?
If you are using pprof via
go tool pprof
, what's yourgo env
output?If you run pprof from GitHub, what's the Git revision?
I am building using the latest Go version which uses the vendored version v0.0.0-20210226084205-cbba55b83ad5
What operating system and processor architecture are you using?
Linux, but this issue is agnostic of operating system
What did you do?
I have code built using Go modules, and when I try to invoke
list
it failsWhat did you expect to see?
Able to view the various profile hits successfully!
What did you see instead?
Proposed remedy
I propose that we instead change this code
pprof/internal/report/source.go
Line 921 in cbba55b
and then also include $GOPATH/pkg/mod as a directory to search from, and I can mail a PR for this, and I am doing so in my local source of Go, but I believe this affects everyone and will need to be distributed
The text was updated successfully, but these errors were encountered: