Skip to content

fix: ntps test remove low=2 scenario#19920

Merged
alexghr merged 1 commit into
nextfrom
mralj/fix/ntps_v3
Jan 25, 2026
Merged

fix: ntps test remove low=2 scenario#19920
alexghr merged 1 commit into
nextfrom
mralj/fix/ntps_v3

Conversation

@mralj

@mralj mralj commented Jan 25, 2026

Copy link
Copy Markdown
Contributor

The CI failed again for the same reason as described in the #19917
This PR just removes the failing scenario altogether until I figure out what's happening, becaue I want to see some numbers in benchmarks

@mralj mralj enabled auto-merge January 25, 2026 10:29
@mralj mralj added this pull request to the merge queue Jan 25, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jan 25, 2026
@alexghr alexghr added this pull request to the merge queue Jan 25, 2026
@AztecBot

Copy link
Copy Markdown
Collaborator

Flakey Tests

🤖 says: This CI run detected 1 tests that failed, but were tolerated due to a .test_patterns.yml entry.

\033FLAKED\033 (8;;http://ci.aztec-labs.com/da7349332fddab30�da7349332fddab308;;�):  yarn-project/end-to-end/scripts/run_test.sh simple src/e2e_p2p/valid_epoch_pruned_slash.test.ts (396s) (code: 1) group:e2e-p2p-epoch-flakes (\033Alex Gherghisan\033: fix: ntps test remove low=2 scenario (#19920))

Merged via the queue into next with commit 4ef4df6 Jan 25, 2026
17 checks passed
@alexghr alexghr deleted the mralj/fix/ntps_v3 branch January 25, 2026 13:04
mrzeszutko added a commit that referenced this pull request Mar 23, 2026
## Summary

- **Restore the `LOW_VALUE_TPS=2` benchmark scenario** that was removed
in PR #19920 after repeated setup timeouts
- **Parallelize wallet creation** in `n_tps.test.ts` by switching from
`timesAsync` (sequential) to `timesParallel`, cutting setup time
proportionally to the number of wallets
- **Add retry logic with backoff** to `deployAccountWithDiagnostics`
that tracks pending transactions across retries, avoiding nullifier
conflicts when a previous tx is still in the mempool under chaos mesh
conditions
- **Set `SEQ_BUILD_CHECKPOINT_IF_EMPTY=true`** in the TPS scenario
environment so the chain keeps advancing during quiet periods
(setup/teardown)

## Details

### Root cause

With `LOW_VALUE_TPS=2`, the test needs 3 wallets (2 low + 1 high). Each
wallet deployment is an on-chain transaction that must be mined. Under
chaos mesh conditions (20% packet drop + latency), sequential deployment
of accounts frequently exceeds the test timeout.

### Changes

**`yarn-project/end-to-end/src/spartan/n_tps.test.ts`**
- Replace `timesAsync` with `timesParallel` for wallet creation — each
wallet gets an independent PXE/node client, so no shared state
- Add try/catch around `getBlockNumber` polling to avoid crashing on
transient RPC errors during setup

**`yarn-project/end-to-end/src/spartan/setup_test_wallets.ts`**
- Wrap the deploy-and-wait cycle in `retry()` with exponential backoff
(5 attempts, [1,2,4,8,16]s delays)
- Use a 600s per-attempt `waitForTx` timeout, with retries providing
cumulative wait of ~3000s
- Track `sentTxHash` across retries: on retry, check if the previous tx
was dropped before deciding to re-send. If the tx is still pending, wait
for it again instead of sending a duplicate (which would cause
`NULLIFIER_CONFLICT` under chaos mesh)
- Pre-check `getContract()` before each retry to skip re-deploy if a
previous attempt succeeded but `waitForTx` timed out
- Check `receipt.isDropped()` explicitly to clear the tracked tx and
trigger a fresh send

**`spartan/environments/tps-scenario.env`**
- Add `SEQ_BUILD_CHECKPOINT_IF_EMPTY=true` to match
`prove-n-tps-fake.env` — ensures empty checkpoint blocks are produced in
quiet slots, keeping the chain live

**`spartan/bootstrap.sh`**
- Re-add `2` to `low_value_tps_list` to restore the benchmark scenario

## Test plan

- CI should run the restored `low_0_1__high_2` TPS benchmark scenario
end-to-end
- Existing lower TPS scenarios (0.1, 0.2, 0.5, 1) should be unaffected
by the retry/parallel changes

Fixes A-492
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants