Exemplo n.º 1
0
    def validate_transaction(self, transaction: BaseOrSpoofTransaction) -> BaseOrSpoofTransaction:

        # Validate the transaction
        transaction.validate()
        self.vm_state.validate_transaction(transaction)

        return transaction
Exemplo n.º 2
0
 def costless_execute_transaction(self,
                                  transaction: BaseOrSpoofTransaction) -> 'BaseComputation':
     with self.override_transaction_context(gas_price=transaction.gas_price):
         free_transaction = transaction.copy(gas_price=0)
         return self.execute_transaction(free_transaction)