Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Won't Fix
-
None
-
None
-
None
-
None
Description
The fabric returns errors as
{Class, Reason, Stack} (see here https://github.com/apache/couchdb-fabric/blob/master/src/fabric_util.erl#L206).
We used to handle this case in chttpd https://github.com/apache/couchdb-chttpd/commit/0592297776fa700134b0d283a5f3c512f0f96533#diff-e5123f75012e2b3a7edc96b2f0a863b0R522.
This was broken in https://github.com/apache/couchdb-chttpd/commit/ec31e09e540dc4916c416247d2eb8d132b51fffd
Steps to reproduce
Issue an invalid request to view for example.
/_design/foo/_view/view1?start_key=%22bbb%22&end_key=%22aaa%22"
The expected result is
400 {
"error": "query_parse_error",
"reason": "No rows can match your key range, reverse your start_key and end_key or set descending=true"
}
The actual result is
500 {
"error": "query_parse_error",
"reason": "No rows can match your key range, reverse your start_key and end_key or set descending=true",
"ref": 3759544136
}