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

runtime-sdk: gas estimate binary search #981

Merged
merged 2 commits into from Jun 20, 2022

Conversation

ptrus
Copy link
Member

@ptrus ptrus commented Jun 8, 2022

Adds configurable gas estimation via binary search support.

Enables fixing some EVM edge cases (#631) where gas estimation depends on actual gas limit used during estimation.

There are some EVM "gotcha's", hopefully the comments explain it well enough.

@codecov
Copy link

codecov bot commented Jun 8, 2022

Codecov Report

Merging #981 (4240c1f) into main (650c887) will decrease coverage by 23.61%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             main     #981       +/-   ##
===========================================
- Coverage   67.94%   44.32%   -23.62%     
===========================================
  Files         127       24      -103     
  Lines       10304     1507     -8797     
===========================================
- Hits         7001      668     -6333     
+ Misses       3278      816     -2462     
+ Partials       25       23        -2     
Impacted Files Coverage Δ
contract-sdk/specs/token/oas20/src/helpers.rs 84.56% <0.00%> (-13.29%) ⬇️
runtime-sdk/modules/evm/src/lib.rs
runtime-sdk/src/modules/core/mod.rs
runtime-sdk/src/modules/core/test.rs
runtime-sdk/src/types/transaction.rs
contract-sdk-macros/src/lib.rs
runtime-sdk/modules/contracts/src/results.rs
contract-sdk/types/src/testing.rs
runtime-sdk/src/modules/accounts/mod.rs
contract-sdk-macros/src/util.rs
... and 94 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 650c887...4240c1f. Read the comment docs.

@ptrus ptrus force-pushed the ptrus/feature/gas-estimate-search branch 6 times, most recently from 729cdaf to d9fe655 Compare June 9, 2022 09:05
runtime-sdk/src/modules/core/mod.rs Outdated Show resolved Hide resolved
runtime-sdk/src/modules/core/mod.rs Outdated Show resolved Hide resolved
runtime-sdk/src/modules/core/mod.rs Show resolved Hide resolved
runtime-sdk/src/modules/core/mod.rs Outdated Show resolved Hide resolved
runtime-sdk/src/modules/core/mod.rs Outdated Show resolved Hide resolved
@ptrus ptrus force-pushed the ptrus/feature/gas-estimate-search branch 6 times, most recently from 0580071 to dd0a52b Compare June 16, 2022 12:30
@ptrus ptrus marked this pull request as ready for review June 16, 2022 13:32
@ptrus ptrus requested a review from pro-wh as a code owner June 16, 2022 13:32
@ptrus ptrus force-pushed the ptrus/feature/gas-estimate-search branch 4 times, most recently from e4cf233 to da6ba24 Compare June 17, 2022 10:57
@ptrus ptrus requested a review from kostko June 17, 2022 16:00
@ptrus ptrus force-pushed the ptrus/feature/gas-estimate-search branch from da6ba24 to 359ab83 Compare June 18, 2022 17:04
runtime-sdk/src/context.rs Outdated Show resolved Hide resolved
@kostko kostko added the c:runtime-sdk Category: Runtime SDK label Jun 20, 2022
@ptrus ptrus force-pushed the ptrus/feature/gas-estimate-search branch from 359ab83 to 6257bf4 Compare June 20, 2022 08:25
@ptrus ptrus force-pushed the ptrus/feature/gas-estimate-search branch from 6257bf4 to 4240c1f Compare June 20, 2022 09:06
@ptrus ptrus merged commit c03d275 into main Jun 20, 2022
@ptrus ptrus deleted the ptrus/feature/gas-estimate-search branch June 20, 2022 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c:runtime-sdk Category: Runtime SDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants