Skip to content

fix: avoid panic in init godeltaprof/http/pprof for go 1.23 #119

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

Merged
merged 2 commits into from
Aug 15, 2024

Conversation

korniltsev
Copy link
Collaborator

@korniltsev korniltsev commented Aug 14, 2024

fix #118

go 1.23 changed the way net/http/pprof registers pprof endpoints by prefixing with "GET "

This leads to panics if godeltaprof does not do the same.

https://github.com/golang/go/blob/9fcffc53593c5cd103630d0d24ef8bd91e17246d/src/net/http/pprof/pprof.go#L98-L97

golang/go@9fcffc5

@korniltsev korniltsev changed the title fix: avoid panic in init godeltaprof/http/pprof fix: avoid panic in init godeltaprof/http/pprof for go 1.23 Aug 14, 2024
@korniltsev korniltsev marked this pull request as ready for review August 15, 2024 08:35
@korniltsev korniltsev requested a review from a team as a code owner August 15, 2024 08:35
Copy link
Contributor

@simonswine simonswine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@korniltsev korniltsev merged commit edd64fd into main Aug 15, 2024
7 checks passed
@korniltsev korniltsev deleted the go123_fix_init_panic branch August 15, 2024 11:01
cristiangreco added a commit to grafana/dskit that referenced this pull request Aug 23, 2024
While godeltaprof v0.1.7 fixed a build issue with go1.23, version v0.1.8
fixes a runtime error.

See grafana/pyroscope-go#119
cristiangreco added a commit to grafana/dskit that referenced this pull request Aug 26, 2024
While godeltaprof v0.1.7 fixed a build issue with go1.23, version v0.1.8
fixes a runtime error.

See grafana/pyroscope-go#119
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

go 1.23 panic at initialization
2 participants