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

Pull request #94 causes http.ErrBodyReadAfterClose #166

Closed
lagren opened this issue Feb 23, 2020 · 2 comments · Fixed by #168
Closed

Pull request #94 causes http.ErrBodyReadAfterClose #166

lagren opened this issue Feb 23, 2020 · 2 comments · Fixed by #168
Milestone

Comments

@lagren
Copy link

lagren commented Feb 23, 2020

I have experienced a bug that is mentioned by @faulkner in #94 (https://github.com/getsentry/sentry-go/pull/94/files#r373130154)

This introduces a new bug. If ioutil.ReadAll returns an error the body is left in a closed state, so reading the body later results in a http.ErrBodyReadAfterClose, so instead of the original error getting sent to Sentry you end up just getting http: invalid Read on closed Body with no way of knowing what the original error was.

According to a follow-up comment, this would be addressed in #117. But that issue was closed without any code changes and I don't see any other issues opened to keep track of this bug.

@rhcarvalho rhcarvalho added this to the v0.6.0 milestone Feb 23, 2020
@rhcarvalho
Copy link
Contributor

@lagren I have a WIP that will address that (this) and #96.

@rhcarvalho
Copy link
Contributor

@lagren could you please try with master?

I'm planning to cut v0.6.0 soon.

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 a pull request may close this issue.

2 participants