Skip to content

Fix for key error when sending broadcast trx

There are two formats for broadcast transaction:

  1. condenser_api format, where request_params['operations'] is list of lists
  2. network_broadcast_api, where request_params['operations'] is list of dict

validator.py has a support only for 1, support for 2 has been added

Fix for: {"exception":"KeyError(0,)","message":"Internal Error","error_id":"65c8a0e4-ecd4-4424-a490-7f87cb0c889a","jrpc_request_id":1,"jussi_request_id":"001113248166147000","event":"Internal Error","logger":"jussi.errors","level":"error"}

while sending: curl -s --data '{"jsonrpc":"2.0", "method":"network_broadcast_api.broadcast_transaction", "params":{"trx":{"ref_block_num":1097,"ref_block_prefix":2181793527,"expiration":"2016-03-24T18:00:21","operations":[{"type":"vote_operation","value":{"voter":"hiveio","author":"alice","permlink":"a-post-by-alice","weight":10000}}],"extensions":[],"signatures":[]},"max_block_age":50}, "id":1}' https://beta.openhive.network

Edited by Dariusz Kędzierski

Merge request reports