Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
net/http: describe where multiple response.WriteHeader calls occur #18761
I see this in an HTTP server log:
Written by the http package here.
It would be nice if it described file+line of the first non-http package function that caused WriteHeader to be called so that it's easier to find the offending code.
I debugged quite a few of these in PHP in a previous life nearly a decade ago.
From that experience I would like to mention that you usually don't know whether the first or the second one is the caller that should have been written the header. So I would suggest reporting both: The first writer and the second one.