Closed Alenar closed 1 week ago
4 files ±0 51 suites ±0 11m 50s ⏱️ +17s 1 446 tests +1 1 446 ✅ +1 0 💤 ±0 0 ❌ ±0 1 657 runs +1 1 657 ✅ +1 0 💤 ±0 0 ❌ ±0
Results for commit 5ca6033a. ± Comparison against base commit 43b267a9.
:recycle: This comment has been updated with latest results.
Content
This PR fix the handling of
404
errors in the aggregator http server.In case of a
404
the custom rejection middleware immediatly emit a rejection (this custom rejection was added to set the appropriate status code for API Version Mistmatch errors). This means that no other middleware would be applied nor our custom headers.Pre-submit checklist
Comments
This problem cascade to the browser javascript
fetch
api, the missing headers make the api immediately throw an error thus making impossible to handle the404
in a idiomatic way.In this example the status code can't be checked in the
then
block since a exception is raised (note: the exception doesn't contains the status code).This problems made more cumbersome the fallback to
Epoch Setting
mechanism used in PR #2128, we had to handle it in thecatch
block without the ability to check that it was indeed a404
or not.