Skip to main content

Module error_codes

Module error_codes 

Source
Expand description

JSON-RPC 2.0 error codes.

Why: Both trusty-memory and trusty-search referenced these constants with slightly drifting numeric types — consolidating here keeps them aligned. What: i32 to match the JSON-RPC 2.0 spec; serde_json serialises these transparently as JSON numbers. Test: error_codes_are_spec_values asserts the canonical numeric values.

Constants§

INTERNAL_ERROR
INVALID_PARAMS
INVALID_REQUEST
METHOD_NOT_FOUND
PARSE_ERROR