Skip to content

Proper JSON-RPC error codes #1464

Description

@ZmnSCPxj

Currently almost all commands just give a -1 error code in all errors. However this is not really particularly useful programmatically: it would be better for progammatic access to be able to determine what the exact error is without having to parse the error message (which is in fact the intent of the error code).

So I want to propose that we change command_fail to accept a proper code argument and make an effort to provide error codes for all error types!

IF we decide to go this route (this issue is a question) then w should probably schedule this for 0.6 also, as we would like to present a reasonably stable JSON-RPC interface.

Inspired-by: @wythe #1463

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions