Skip to content

Commit

Permalink
remove postOpGasLimit from estimateUserOperationGas
Browse files Browse the repository at this point in the history
The value of postOpGasLimit can't be reliably estimated: the paymaster
depends on this value, and can't trust the account to estimate a proper
value, so it must require a fixed, known value.
  • Loading branch information
drortirosh committed Apr 25, 2024
1 parent 2b1aac4 commit 2159461
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions erc/ERCS/erc-4337.md
Original file line number Diff line number Diff line change
Expand Up @@ -672,14 +672,16 @@ Still, it might require putting a "semi-valid" signature (e.g. a signature in th

* **preVerificationGas** gas overhead of this UserOperation
* **verificationGasLimit** actual gas used by the validation of this UserOperation
* **paymasterVerificationGasLimit** actual gas used by used for paymaster verification (if paymaster exists in the UserOperation)
* **callGasLimit** value used by inner account execution
* **paymasterVerificationGasLimit** value used for paymaster verification (if paymaster exists in the UserOperation)
* **paymasterPostOpGasLimit** value used for paymaster post op execution (if paymaster exists in the UserOperation)

**Note:** actual postOpGasLimit cannot be reliably estimated. Paymasters should provide this value to account,
and require that specific value on-chain.

##### Error Codes:

Same as `eth_sendUserOperation`
This operation may also return an error if the inner call to the account contract reverts.
This operation may also return an error if the inner call to the account contract (or paymaster's postOp) revert.

#### * eth_getUserOperationByHash

Expand Down

0 comments on commit 2159461

Please sign in to comment.