Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions yarn-project/bot/src/factory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import { PrivateTokenContract } from '@aztec/noir-contracts.js/PrivateToken';
import { TokenContract } from '@aztec/noir-contracts.js/Token';
import { TestContract } from '@aztec/noir-test-contracts.js/Test';
import type { ContractInstanceWithAddress } from '@aztec/stdlib/contract';
import { GasSettings } from '@aztec/stdlib/gas';
import type { AztecNode, AztecNodeAdmin } from '@aztec/stdlib/interfaces/client';
import { deriveSigningKey } from '@aztec/stdlib/keys';
import { EmbeddedWallet } from '@aztec/wallets/embedded';
Expand Down Expand Up @@ -222,13 +221,11 @@ export class BotFactory {

const paymentMethod = new FeeJuicePaymentMethodWithClaim(accountManager.address, claim);
const deployMethod = await accountManager.getDeployMethod();
const maxFeesPerGas = (await this.aztecNode.getCurrentMinFees()).mul(1 + this.config.minFeePadding);
const gasSettings = GasSettings.default({ maxFeesPerGas });

await this.withNoMinTxsPerBlock(async () => {
const { txHash } = await deployMethod.send({
from: AztecAddress.ZERO,
fee: { gasSettings, paymentMethod },
fee: { paymentMethod },
wait: NO_WAIT,
});
this.log.info(`Sent tx for account deployment with hash ${txHash.toString()}`);
Expand Down
11 changes: 4 additions & 7 deletions yarn-project/end-to-end/src/e2e_bot.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,8 @@ describe('e2e_bot', () => {
// approve/deposit calls in bridgeL1FeeJuice. Indices 8 and 9 are used by other tests below.
l1PrivateKey: new SecretValue(bufferToHex(getPrivateKeyFromIndex(7)!)),
flushSetupTransactions: true,
// Increase fee headroom to handle fee volatility from rapid block building in tests.
// Fees can escalate >10x due to blocks built by earlier tests and bridge operations.
minFeePadding: 99,
// Fee headroom to handle fee volatility from rapid block building in tests.
minFeePadding: 9,
};

{
Expand Down Expand Up @@ -180,10 +179,8 @@ describe('e2e_bot', () => {
// See comment above — dedicated L1 account to avoid nonce races with the sequencer.
l1PrivateKey: new SecretValue(bufferToHex(getPrivateKeyFromIndex(7)!)),
flushSetupTransactions: true,
// Increase fee headroom to handle fee volatility from rapid block building in tests.
// This test is especially susceptible because changing salt triggers a new bridge claim,
// adding more block building on top of what earlier tests already produced.
minFeePadding: 99,
// Fee headroom to handle fee volatility from rapid block building in tests.
minFeePadding: 9,
};

{
Expand Down
Loading