Skip to content

Implement estimate_gas for EVM smart contracts. #3759

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

Open
Tracked by #3173
MathieuDutSik opened this issue Apr 14, 2025 · 0 comments
Open
Tracked by #3173

Implement estimate_gas for EVM smart contracts. #3759

MathieuDutSik opened this issue Apr 14, 2025 · 0 comments
Assignees

Comments

@MathieuDutSik
Copy link
Contributor

MathieuDutSik commented Apr 14, 2025

The function estimate_gas of Ethereum allows for estimating the gas being used for the run. It allows us to know how much gas is needed.

There is no standard that needs to be followed, and both 0 and u64::MAX could be put without breaking anything. Yet, it is useful to give a reasonable value.

We can use the handle_query for that functionality since it does not modify the state. It will not work if that EVM smart contract calls a Wasm smart contract since the Wasm does not have an estimator of gas usage.

@MathieuDutSik MathieuDutSik changed the title Implement the estimate_gas Implemen estimate_gas Apr 14, 2025
@MathieuDutSik MathieuDutSik self-assigned this Apr 14, 2025
@MathieuDutSik MathieuDutSik changed the title Implemen estimate_gas Implement estimate_gas for EVM smart contracts. Apr 14, 2025
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

1 participant