diff --git a/yarn-project/aztec-node/src/aztec-node/server.ts b/yarn-project/aztec-node/src/aztec-node/server.ts index fa07a23ced6f..631e4f6190d6 100644 --- a/yarn-project/aztec-node/src/aztec-node/server.ts +++ b/yarn-project/aztec-node/src/aztec-node/server.ts @@ -341,7 +341,7 @@ export class AztecNodeService implements AztecNode { const timer = new Timer(); this.log.info(`Received tx ${tx.getTxHash()}`); - if ((await this.validateTx(tx)) === false) { + if (! await this.validateTx(tx)) { this.metrics.receivedTx(timer.ms(), false); return; } diff --git a/yarn-project/aztec.js/src/contract/contract_function_interaction.ts b/yarn-project/aztec.js/src/contract/contract_function_interaction.ts index 3ade1883c3f5..c8f2774b4d91 100644 --- a/yarn-project/aztec.js/src/contract/contract_function_interaction.ts +++ b/yarn-project/aztec.js/src/contract/contract_function_interaction.ts @@ -23,7 +23,7 @@ export type SimulateMethodOptions = { from?: AztecAddress; /** Gas settings for the simulation. */ gasSettings?: GasSettings; - /** Simulate without validating tx against current state. */ + /** Simulate without validating tx results against current state. */ offline?: boolean; }; diff --git a/yarn-project/circuit-types/src/interfaces/aztec-node.ts b/yarn-project/circuit-types/src/interfaces/aztec-node.ts index f20195d0fe04..0eede2934d38 100644 --- a/yarn-project/circuit-types/src/interfaces/aztec-node.ts +++ b/yarn-project/circuit-types/src/interfaces/aztec-node.ts @@ -317,8 +317,9 @@ export interface AztecNode { simulatePublicCalls(tx: Tx): Promise; /** - * Validates the correctness of the execution, namely that a transaction is valid if and - * only if the transaction can be added to a valid block at the current state. + * Returns true if the transaction is valid for inclusion at the current state. Valid transactions can be + * made invalid by *other* transactions if e.g. they emit the same nullifiers, or come become invalid + * due to e.g. the max_block_number property. * @param tx - The transaction to validate for correctness. */ validateTx(tx: Tx): Promise;