Loading multiple bug ids over REST (i.e. /bug/?permissive=1&ids=1&ids=2...) does not honor the permissive parameter properly

NEW
Unassigned

Status

()

3 years ago
3 years ago

People

(Reporter: dkl, Unassigned)

Tracking

Details

(Reporter)

Description

3 years ago
Even if you pass permissive=1 and you cannot see one of the bug ids that was provided, it will die with the error:

{
   "code" : 102,
   "documentation" : "http://www.bugzilla.org/docs/tip/en/html/api/",
   "error" : true,
   "message" : "You are not authorized to access bug 1. To see this bug, you must first log in to an account with the appropriate permissions."
}

Even if you are authenticated and cannot see a bug in the list, permissive=1 is supposed to push the fault into a @faults array and allow you get back the ones you can see. 

We use eval { $bug = Bugzilla::Bug->check($bug_id); }; if permissive=1 but somehow JSONRPC is seeing the error and not returning normal results even if we leave Bug.get with a list of bug hashes. This is due to JSONRPC setting the error_response_header which REST.pm looks for. It the returns the error response instead of the correct status 200 response.
You need to log in before you can comment on or make changes to this bug.