Suggestion: remove default cache timeout
Ethers Version
6
Describe the Problem
The default deduping timeout of 250ms could be dangerous as it could lead to mempool state sync issues, that can consequently lead to failure of actions (e.g. if a consumer depends on a eth_getTxCount(..., "pending") or other blockchain state that depends on the mempool/"pending".
I would recommend for the deduping timeout to be opt-in, or to disable this for block tags.
https://github.com/ethers-io/ethers.js/blob/main/src.ts/providers/abstract-provider.ts#L427
I’ve been considering this for a while.
I think it makes sense to include along with the change of the ProviderOptions.staticNetwork to true (BrowserProvider will explicitly set this to false unless overridden).
I’ll queue it up for an upcoming minor bump and make an announcement on the ethers twitter.