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

internal/ethapi: add basefee to block overrides #25219

Merged
merged 1 commit into from
Jul 5, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions internal/ethapi/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -889,6 +889,7 @@ type BlockOverrides struct {
GasLimit *hexutil.Uint64
Coinbase *common.Address
Random *common.Hash
BaseFee *hexutil.Big
}

// Apply overrides the given header fields into the given block context.
Expand All @@ -914,6 +915,9 @@ func (diff *BlockOverrides) Apply(blockCtx *vm.BlockContext) {
if diff.Random != nil {
blockCtx.Random = diff.Random
}
if diff.BaseFee != nil {
blockCtx.BaseFee = diff.BaseFee.ToInt()
}
}

func DoCall(ctx context.Context, b Backend, args TransactionArgs, blockNrOrHash rpc.BlockNumberOrHash, overrides *StateOverride, timeout time.Duration, globalGasCap uint64) (*core.ExecutionResult, error) {
Expand Down