JSON-RPC WebService should return errors identically numerically coded as XML-RPC WebService

RESOLVED FIXED in Bugzilla 3.6

Status

()

Bugzilla
WebService
RESOLVED FIXED
8 years ago
8 years ago

People

(Reporter: Max Kanat-Alexander, Assigned: Max Kanat-Alexander)

Tracking

3.5.3
Bugzilla 3.6
Bug Flags:
approval +
approval3.6 +
blocking3.6 +

Details

Attachments

(1 attachment)

(Assignee)

Description

8 years ago
I figured out how we can return identical errors codes as XML-RPC--we just have to override _errors to adjust the error code.
Flags: blocking3.6+
(Assignee)

Updated

8 years ago
Summary: JSON-RPC WebService should return errors identically coded as XML-RPC WebService → JSON-RPC WebService should return errors identically numerically coded as XML-RPC WebService
(Assignee)

Comment 1

8 years ago
Created attachment 427726 [details] [diff] [review]
v1

Okay, this fixes things, and it also standardizes the error format between JSON-RPC 1.0 and 1.1. (The JSON-RPC 1.0 spec actually doesn't specify an error format, and the error format that JSON::RPC was returning didn't include an error code.)
Assignee: webservice → mkanat
Status: NEW → ASSIGNED
Attachment #427726 - Flags: review?(dkl)
Comment on attachment 427726 [details] [diff] [review]
v1

Looks good and works as described. r=dkl
Attachment #427726 - Flags: review?(dkl) → review+
(Assignee)

Updated

8 years ago
Flags: approval3.6+
Flags: approval+
(Assignee)

Comment 3

8 years ago
  Thanks. :-)

Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/trunk/                       
modified Bugzilla/WebService/Server/JSONRPC.pm
Committed revision 7024. 

Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/3.6/                         
modified Bugzilla/WebService/Server/JSONRPC.pm
Committed revision 6998.
Status: ASSIGNED → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.