This repository has been archived by the owner on Sep 18, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Aborted requests show status code 200 in response event #729
Comments
Also, notice the actual request failed even though the status code is showing as 200. 😕 |
Route handler looks like: {
config: {
auth: false,
handler() {
return new Promise(function (resolve, reject) {
setTimeout(function () {
reject(new Error('adam'));
}, 4000);
});
}
},
method: 'GET',
path: '/version'
} I cancel the request from the browser before it finishes to produce the error. |
Scratch that. The 200 appears to be emanating from node's ServerResponse |
@hueniverse :: I see you tackled hapijs/hapi#3561. This seems related. Thoughts on if this is a bug or expected behavior? |
@clcpolevaulter I am not sure what to do about this yet, but go ahead and open an issue on hapi. |
This was referenced Nov 16, 2020
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Notice that the response event below has a
statusCode
of 200 even though the request was aborted by the client. When logging this event, the status code becomes misleading when troubleshooting. Is there a way to set the status code to 499 instead? This seems related to hapijs/hapi#3561.The text was updated successfully, but these errors were encountered: