diff --git a/proxy/common_neon/transaction_sender.py b/proxy/common_neon/transaction_sender.py index 235419282..c48ca44e6 100644 --- a/proxy/common_neon/transaction_sender.py +++ b/proxy/common_neon/transaction_sender.py @@ -19,8 +19,8 @@ from .emulator_interactor import call_emulated from .layouts import ACCOUNT_INFO_LAYOUT from .neon_instruction import NeonInstruction -from .solana_interactor import SolanaInteractor, check_if_continue_returned, check_for_errors,\ - check_if_program_exceeded_instructions, check_if_storage_is_empty_error +from .solana_interactor import SolanaInteractor, check_if_continue_returned, \ + check_if_program_exceeded_instructions, check_for_errors from ..environment import EVM_LOADER_ID from ..plugin.eth_proto import Trx as EthTrx @@ -428,7 +428,7 @@ def call_continue_step(self): logger.debug("Step count {}".format(step_count)) try: - result = self.sender.send_measured_transaction(trx, self.eth_trx, 'ContinueV02') + result = self.sender.send_measured_transaction(trx, self.eth_trx, self.instruction_type) return result except SendTransactionError as err: if check_if_program_exceeded_instructions(err.result): @@ -448,25 +448,15 @@ def call_cancel(self): def call_continue_bucked(self): logger.debug("Send bucked combined: %s", self.instruction_type) - steps = self.steps - receipts = [] for index in range(math.ceil(self.steps_emulated/self.steps) + self.addition_count()): try: - trx = self.make_combined_trx(steps, index) + trx = self.make_combined_trx(self.steps, index) receipts.append(self.sender.send_transaction_unconfirmed(trx)) - except SendTransactionError as err: - logger.error(f"Failed to call continue bucked, error: {err.result}") - if check_if_storage_is_empty_error(err.result): - pass - elif check_if_program_exceeded_instructions(err.result): - steps = int(steps * 90 / 100) - else: - raise except Exception as err: logger.debug(str(err)) - if str(err).startswith('failed to get recent blockhash'): - pass + if len(receipts) > 0: + break else: raise