Nonce is currently computed by directly asking latest tx nonce.
This is correct in most case, except if u have stuck tx.
In that case you can either send a new tx with same nonce but high gas to replace current tx or create a new tx with pending nonce +1
Both solution are valid and we need to be a better facilitator here.
Here are the change suggestion:
[ ] being able to tweek gas and nonce per transaction with hint about what is going to happen
e.g:
if the nonce is a known one, it is a replacement/cancellation and as such gas must be higher than replaced tx
if the nonce is more than a pending one: this is a new tx (probably normal flow)
if the nonce is more than +1 from a known one, it can be either a mistake or because a pending tx has been sent outside status. So this is a legit case but not something we can fully resolve
@John-44 @benjthayer I know we have in design the advance input but maybe we should also consider those usecases?
Nonce is currently computed by directly asking latest tx nonce. This is correct in most case, except if u have stuck tx. In that case you can either send a new tx with same nonce but high gas to replace current tx or create a new tx with pending nonce +1
Both solution are valid and we need to be a better facilitator here. Here are the change suggestion:
@John-44 @benjthayer I know we have in design the advance input but maybe we should also consider those usecases?