Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
mouseless0x committed Jan 20, 2025
1 parent 5f58434 commit 7cf36d5
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions docs/pages/permissionless/faqs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ For more details about the `saltNonce` parameter and other configuration options

## Getting `preVerificationGas is not enough` errors?

This error occurs when the gas estimation for your UserOperation's pre-verification phase is insufficient. You might see an error message like this:
This error occurs when a userOperation is submitted with a preVerificationGas that is insufficient to cover the offchain overhead.
You might see an error message like:

```json
{
Expand All @@ -83,16 +84,16 @@ The `preVerificationGas` accounts for:

This error typically occurs in two scenarios:

1. When calling `eth_estimateUserOperationGas` with a signature that is not the same length as the real signature
2. When submitting a UserOperation after the bundler's commitment has expired
1. When calling `eth_estimateUserOperationGas` with a userOperation signature that is not the same length as the real signature.
2. When submitting a UserOperation after the bundler's preVerificationGas commitment has expired.

To resolve this issue:

1. Ensure proper dummy signature is used during estimation:
1. Ensure proper dummy signature is used during estimation to ensure proper L1DataCost calculations:
- Provide a semi-valid dummy signature that matches your final signature's length
- The signature should be semi valid such that the validation doesn't revert

2. Account for gas estimation timing:
- The bundler commits to the estimated `preVerificationGas` for 30 seconds
- Submit your UserOperation within this window to avoid insufficient gas errors
- If needed, increase `preVerificationGas` by ~15000 units as a buffer
- You should submit your UserOperation within this window to avoid insufficient preVerificationGas errors
- If you are submitting after the window, you can add a fixed overhead to your `preVerificationGas` to increase the chances it gets included

0 comments on commit 7cf36d5

Please sign in to comment.