Skip to content

Conversation

@binnn6
Copy link

@binnn6 binnn6 commented Nov 17, 2025

err = r.BindJSON(&request) will write http header to client if err. After this, r.JSON(200, resp) willl cause warning Headers were already written. Wanted to override status code 400 with 200

[GIN-debug] [WARNING] Headers were already written. Wanted to override status code 400 with 200
[GIN] 2025/11/17 - 03:42:24 | 400 | 110.582µs | 172.17.0.1 | POST "/v1/sandbox/run"
[GIN] 2025/11/17 - 03:42:24 | 400 | 133.045µs | 172.17.0.1 | POST "/v1/sandbox/run"

Signed-off-by: binnnliu <[email protected]>
@binnn6
Copy link
Author

binnn6 commented Nov 19, 2025

@Yeuoly Could you please review this PR?

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.

1 participant