Skip to content

Conversation

@rjl493456442
Copy link
Member

@rjl493456442 rjl493456442 commented Jan 28, 2021

This adds support for state overrides when tracing calls.

Fixes #22197

TODO

  • Updates the tracer API doc

Comment on lines +735 to +769
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to think a while to figure out why this is needed. So essentially, you do this to clear out the StateOverrides, so it doesn't get applied a second time later on?
If that's the case, why not just set it to nil?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because api.traceTx only accepts the TraceConfig, while TraceCall use the TraceCallConfig. Here just do the parameter conversion.

Copy link
Contributor

@holiman holiman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One question, but generally LGTM. Haven't tested it

eth/tracers: fix testing

eth, internal: add tests

internal: fix imports

eth/traces: handle invalid block parameter

eth/tracers: fix json field conflict
@rjl493456442
Copy link
Member Author

Rebased the PR

@holiman holiman added this to the 1.10.3 milestone Apr 21, 2021
@holiman holiman merged commit dd9c322 into ethereum:master Apr 21, 2021
atif-konasl pushed a commit to frozeman/pandora-execution-engine that referenced this pull request Oct 15, 2021
Adds an an optional parameter `overrides *map[common.Address]account` to the `eth_call` API in order for the caller to  can customize the state.
gzliudan added a commit to gzliudan/XDPoSChain that referenced this pull request Jul 26, 2025
gzliudan added a commit to gzliudan/XDPoSChain that referenced this pull request Jul 30, 2025
gzliudan added a commit to gzliudan/XDPoSChain that referenced this pull request Aug 8, 2025
gzliudan added a commit to gzliudan/XDPoSChain that referenced this pull request Aug 13, 2025
gzliudan added a commit to XinFinOrg/XDPoSChain that referenced this pull request Aug 20, 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

Successfully merging this pull request may close these issues.

Extend the "TraceCall" API so that the state override can be support

2 participants