This repository was archived by the owner on Apr 26, 2024. It is now read-only.
send 404 as http-status when filter-id is unknown to the server#2380
Merged
richvdh merged 12 commits intomatrix-org:developfrom Oct 10, 2019
Merged
send 404 as http-status when filter-id is unknown to the server#2380richvdh merged 12 commits intomatrix-org:developfrom
richvdh merged 12 commits intomatrix-org:developfrom
Conversation
This fixed the weirdness of 400 vs 404 as http status code in the case the filter id is not known by the server. As e.g. matrix-js-sdk expects 404 to catch this situation this leads to unwanted behaviour.
Member
|
Can one of the admins verify this patch? |
2 similar comments
Member
|
Can one of the admins verify this patch? |
Member
|
Can one of the admins verify this patch? |
respond 404 - No such filter with errorcode "M_NOT_FOUND" instead of 404 - No such row with errorcode "M_UNKNOWN" when filter-id is unknown to the server
Member
|
@matrixbot test this please |
richvdh
suggested changes
Jul 29, 2019
Member
richvdh
left a comment
There was a problem hiding this comment.
the changes to the GET api look ok, but I'm unconvinced by the change to /sync
Member
|
I can't believe it's taken us over 2 years to land this patch. @anoadragon453 are you able to take it on? |
richvdh
reviewed
Jul 29, 2019
Member
|
I'm fed up with the fact that this trivial PR has been bitrotting for so long, and am going to fix it up and land it. |
Codecov Report
@@ Coverage Diff @@
## develop #2380 +/- ##
==========================================
Coverage ? 63.31%
==========================================
Files ? 331
Lines ? 36433
Branches ? 6018
==========================================
Hits ? 23069
Misses ? 11722
Partials ? 1642 |
richvdh
approved these changes
Oct 10, 2019
babolivier
pushed a commit
that referenced
this pull request
Sep 1, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This fixed the weirdness of 400 vs 404 as http status code in the case
the filter id is not known by the server.
E.g. matrix-js-sdk expects 404 here to catch this situation.
See the discussion in #matrix-dev:matrix.org