-
Without adding a gasLimit to my transaction, I get the error When I do specify a gasLimit, my error becomes Here are my transaction options:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Can you once try passing a const estimatedGas = await provider.estimateGas({
to: targetContract,
data: encodedPayload,
value: txOptions.value,
+ from: wallet.address
}); |
Beta Was this translation helpful? Give feedback.
Can you once try passing a
from
field to the estimateGas? Since you are directly using the provider.estimateGas, it has no context about the msg.sender.const estimatedGas = await provider.estimateGas({ to: targetContract, data: encodedPayload, value: txOptions.value, + from: wallet.address });