Skip to content
This repository was archived by the owner on Oct 19, 2024. It is now read-only.

test: fix duplicate tx flakes by rotating through a list of wallets #451

Merged
merged 3 commits into from
Sep 14, 2021

Conversation

gakonst
Copy link
Owner

@gakonst gakonst commented Sep 14, 2021

Is this the day our tests stop being flaky? Maybe? We now rotate over private keys associated with a mnemonic, instead of having a bunch of keys lying around and hoping we don't duplicate them somewhere & introduce race conditions.

I've pre-funded the wallets generated as documented here

let tx = TransactionRequest::new()
.nonce(nonce)
.to(addr)
// 0.1 eth per wallet
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// 0.1 eth per wallet
// 1 eth per wallet

without fetch_add, it's possible that 2 loads happen for the same id before the `store` mutex is acquired'
@gakonst gakonst merged commit 79bf896 into master Sep 14, 2021
@gakonst gakonst deleted the fix/flaky-tests branch September 14, 2021 13:40
meetmangukiya pushed a commit to meetmangukiya/ethers-rs that referenced this pull request Mar 21, 2022
* Added workaround for LogNamedDecimalIntFilter not handling negative ints

* Added test for LogNamedDecimalIntFilter with negative values

* Reverted changes that caused a regression in dec uint log formatting

* Fixed log formatting for LogNamedDecimalUintFilter and LogNamedDecimalIntFilter and added additional tests

* Removed redundant conversion

* Use Signs existing Display impl
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant