lisk-sdk
lisk-sdk copied to clipboard
Update `error` method of interoperability module
Description
Update error
method of BaseInteroperabilityMethod (mainchain/sidechain) module
def error(ccm: CCM, errorStatus: uint32) -> None:
# Error codes from 0 to MAX_RESERVED_ERROR_STATUS (included) are reserved to the Interoperability module
if 0 <= errorStatus <= MAX_RESERVED_ERROR_STATUS:
raise Exception('Invalid error status.')
return send(
EMPTY_FEE_ADDRESS,
ccm.module,
ccm.crossChainCommand,
ccm.sendingChainID,
0,
errorStatus,
ccm.params
)
Acceptance Criteria
- Should have corresponding unit tests
Additional Information
- LIP Updated PR https://github.com/LiskHQ/lips/pull/148