Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add client support for monitoring gas estimate for pragma callback #166

Open
loothero opened this issue Aug 20, 2024 · 0 comments
Open

Add client support for monitoring gas estimate for pragma callback #166

loothero opened this issue Aug 20, 2024 · 0 comments
Assignees

Comments

@loothero
Copy link
Member

The contract includes a max vrf callback fee of $0.10 on mainnet. This is to prevent Pragma from paying more in gas than they are earning during gas spikes.

The contract includes a capability to allow players to bypass this by manually adding ETH to the LS contract which will be used to increase that players max vrf callback fee. The weakness in the current implementation is that the player needs to add to their vrf premium before the level up occurs. Once the level up occurs, LS contract will have requested VRF with the default max vrf callback fee and there is no way to re-request, nor do we want one to protect the integrity of the randomness system.

The solution is for clients to monitor the estimated gas cost for calling the LS receive_random_words and notify users when the estimate is over $0.10. This notification should let them know that gas fees are currently high and that if they want to avoid delays with VRF responses, they will need to pay a bit more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants