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
When testing some DELETE endpoints that return http 204 Axios just abruptly fails and is unable to capture the response.
It throws this exception, mentioning that the maxContentLength has been exceeded even though no maximum has been specified.
It seems like this error message is just a generic one that is shown when the stream is aborted. As the condition for it to be shown shouldn't occur when no max is set.
This is also confirmed because if I do provide a limit, the error messages still shows even though I'm not possibly exceeding the limit.
I think there issue is somewhere between prism proxy and axios, as based on the prism logs the request is being forwarded to the API, processed and returned, its just Axios throws this exception when processing the return.
I captured the request coming back from the prism proxy using wireshark and it looks like this:
and i can see in the prism logs that request succeeded
To Reproduce
Its a bit challenging to provide a sample application but the steps are as follows.
Have some DELETE endpoint that returns 204 no content.
Install prism proxy and point proxy to your environment
Make Axios.delete call to the prism proxy and the request between prism and API will succeed but fail between prism and axios.
Axios will throw exception.
Code snippet
No response
Expected behavior
I would expect that Axios can simply process this response and return the status code and headers like usual. It would also be better to have a clearer error message since what is shown in the error isn't really what's happening.
Axios Version
1.6.8
Adapter Version
No response
Browser
No response
Browser Version
No response
Node.js Version
20.11.1
OS
windows 10
Additional Library Versions
@stoplight/prism-cli 5.7.0
Additional context/Screenshots
No response
The text was updated successfully, but these errors were encountered:
Describe the bug
Using Axios as part of my API tests to make calls to an API Gateway. To validate these calls match the API spec they are being routed through the prism proxy (https://docs.stoplight.io/docs/prism/72d69fb629de0-validation-proxy)
When testing some DELETE endpoints that return http 204 Axios just abruptly fails and is unable to capture the response.
It throws this exception, mentioning that the maxContentLength has been exceeded even though no maximum has been specified.
It seems like this error message is just a generic one that is shown when the stream is aborted. As the condition for it to be shown shouldn't occur when no max is set.
This is also confirmed because if I do provide a limit, the error messages still shows even though I'm not possibly exceeding the limit.
I think there issue is somewhere between prism proxy and axios, as based on the prism logs the request is being forwarded to the API, processed and returned, its just Axios throws this exception when processing the return.
I captured the request coming back from the prism proxy using wireshark and it looks like this:
and i can see in the prism logs that request succeeded
To Reproduce
Its a bit challenging to provide a sample application but the steps are as follows.
Code snippet
No response
Expected behavior
I would expect that Axios can simply process this response and return the status code and headers like usual. It would also be better to have a clearer error message since what is shown in the error isn't really what's happening.
Axios Version
1.6.8
Adapter Version
No response
Browser
No response
Browser Version
No response
Node.js Version
20.11.1
OS
windows 10
Additional Library Versions
Additional context/Screenshots
No response
The text was updated successfully, but these errors were encountered: