broadcast#
API documentation for tradeexecutor.ethereum.execution.broadcast Python function.
- broadcast(web3, ts, instructions, confirmation_block_count=0, ganache_sleep=0.5)[source]#
Broadcast multiple transactions and manage the trade executor state for them.
Note
The node provider may or may not support broadcasting multiple transactions without confirming existing ones. For example, LlamaNode will give nonce too low error. We will try to deal with this in the middleware.
- Returns:
Map of transaction hashes to watch
- Parameters:
web3 (Web3) –
ts (datetime) –
instructions (List[TradeExecution]) –
confirmation_block_count (int) –
- Return type:
Dict[HexBytes, Tuple[TradeExecution, BlockchainTransaction]]