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 antehandler for EVM to check gas exceed limit or not #1821

Merged
merged 25 commits into from
Aug 30, 2024
Merged

Conversation

yzang2019
Copy link
Contributor

@yzang2019 yzang2019 commented Aug 15, 2024

Describe your changes and provide context

when process the proposal block, sei protocol will check the gas fee is valid or not, if totalGasWanted is bigger than ctx.ConsensusParams().Block.MaxGas will return false,

And then in the tendermint will reject the proposal in validblock, but the bad thing is the sei protcol try to process this block in a loop and will not produce the new block. so will lead to the sei network not being able to confirm new transactions.

Testing performed to validate your change

Tested locally

Copy link

codecov bot commented Aug 19, 2024

Codecov Report

Attention: Patch coverage is 32.00000% with 17 lines in your changes missing coverage. Please review.

Project coverage is 60.69%. Comparing base (f50837e) to head (a01f1cd).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
app/app.go 42.10% 8 Missing and 3 partials ⚠️
x/evm/ante/basic.go 0.00% 6 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1821      +/-   ##
==========================================
+ Coverage   60.67%   60.69%   +0.01%     
==========================================
  Files         258      258              
  Lines       22716    22734      +18     
==========================================
+ Hits        13783    13798      +15     
- Misses       7952     7954       +2     
- Partials      981      982       +1     
Files with missing lines Coverage Δ
x/evm/ante/basic.go 50.00% <0.00%> (-9.38%) ⬇️
app/app.go 66.24% <42.10%> (-0.32%) ⬇️

... and 2 files with indirect coverage changes

yzang2019 and others added 16 commits August 26, 2024 19:10
* main:
  Increase timeout for evm hardhat tests (#1827)
  Fork event manager when creating EVM snapshots (#1831)
  Gas mispricing in cw vm patch (#1824)
  Remove dex actually (#1816)
  Bump seidb to fix receipt missing on restart issue (#1817)
* main:
  feat: limit MsgExec nested level to prevent excessive nesting (#1826)
  [WIP] Add State Store Archive Node Migration (#1772)
  Add associate with pubkey precompile method (#1798)
  Show CW transactions that have synthetic EVM events in eth_getBlock* response (#1832)
@yzang2019 yzang2019 enabled auto-merge (squash) August 28, 2024 14:06
@yzang2019 yzang2019 disabled auto-merge August 29, 2024 06:22
@yzang2019 yzang2019 enabled auto-merge (squash) August 30, 2024 18:28
@yzang2019 yzang2019 merged commit 942e73d into main Aug 30, 2024
48 of 49 checks passed
@yzang2019 yzang2019 deleted the yzang/SEI-7926 branch August 30, 2024 21:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants