You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If an http request fails I expect Insomnia to show the http status code (4xx, 5xx, etc) and the error message in the preview. This used to work but broke recently.
Actual Behavior
When there is a request failure the http status code is not displayed and an internal error message is shown in the preview. The error message is:
message: undefined; stack: Error: message: Cannot read properties of undefined (reading '0'); stack: TypeError: Cannot read properties of undefined (reading '0')
at fn0 (eval at S (file:///Applications/Insomnia.app/Contents/Resources/app.asar/hiddenBrowserWindow-Ci3kk9w5.js:1:664), <anonymous>:12:21)
at eval (eval at S (file:///Applications/Insomnia.app/Contents/Resources/app.asar/hiddenBrowserWindow-Ci3kk9w5.js:1:664), <anonymous>:22:13)
at S (file:///Applications/Insomnia.app/Contents/Resources/app.asar/hiddenBrowserWindow-Ci3kk9w5.js:8:25)
at async file:///Applications/Insomnia.app/Contents/Resources/app.asar/hiddenBrowserWindow-Ci3kk9w5.js:1:346
at port.onmessage (/Applications/Insomnia.app/Contents/Resources/app.asar/preload.js:145:18)
Here is a recording of the issue happening when calling an endpoint multiple times until it hits a rate limit (429).
And this screenshots show a 500 that doesn't get properly displayed in preview.
Hi @LunaticoCR,
Thanks for the very detailed report, this error message is from scripts.
Please check if there's any part code which accesses the first element of an array while the array is undefined.
Yes, eventually after I had opened this ticket I realised that it was from a after-response script, I had duplicated another request that had these.
There was nothing in that error that hinted to me that this came from a script failure. Also, shouldn't request result and script result/error be two separate things? I think there's room for improvement in the UI for this.
Yeah, in reality it's more like an unhandled internal error that surfaced to the UI right? I've seen this error even when the underlying http request succeeds with a 200 OK. But this makes it look like it failed for some obscure reason.
It would be ok if this error was shown in the Tests tab in the response panel, but the http response code and body shouldn't be affected by it.
Uh oh!
There was an error while loading. Please reload this page.
Expected Behavior
If an http request fails I expect Insomnia to show the http status code (4xx, 5xx, etc) and the error message in the preview. This used to work but broke recently.
Actual Behavior
When there is a request failure the http status code is not displayed and an internal error message is shown in the preview. The error message is:
Here is a recording of the issue happening when calling an endpoint multiple times until it hits a rate limit (429).
And this screenshots show a 500 that doesn't get properly displayed in preview.
Reproduction Steps
Make a request that fails.
Is there an existing issue for this?
Which sync method do you use?
Additional Information
This used to work fine a few releases ago.
Insomnia Version
11.0.2
What operating system are you using?
macOS
Operating System Version
Sequoia 15.4.1
Installation method
download
Last Known Working Insomnia version
No response
The text was updated successfully, but these errors were encountered: