def make_receipt(base_header: BlockHeaderAPI, transaction: SignedTransactionAPI, computation: ComputationAPI, state: StateAPI) -> ReceiptAPI: receipt_without_state_root = make_frontier_receipt( base_header, transaction, computation) return receipt_without_state_root.copy( state_root=state.make_state_root())
def make_receipt(cls, base_header: BlockHeaderAPI, transaction: SignedTransactionAPI, computation: ComputationAPI, state: StateAPI) -> ReceiptAPI: gas_used = base_header.gas_used + cls.finalize_gas_used( transaction, computation) receipt_without_state_root = make_frontier_receipt( computation, gas_used) return receipt_without_state_root.copy( state_root=state.make_state_root())