Skip to content

Conversation

Unheilbar
Copy link
Collaborator

@Unheilbar Unheilbar commented Oct 17, 2025

JIRA

Execution clients with REVM backend apply EIP-3607 (reject caller with code) even for eth_call's, therefore when to address is a contract, our calls fail.
There is no practical reasons to set from = to address for eth_call's.

Copy link
Contributor

I see you updated files related to core. Please run pnpm changeset in the root directory to add a changeset as well as in the text include at least one of the following tags:

  • #added For any new functionality added.
  • #breaking_change For any functionality that requires manual action for the node to boot.
  • #bugfix For bug fixes.
  • #changed For any change to the existing functionality.
  • #db_update For any feature that introduces updates to database schema.
  • #deprecation_notice For any upcoming deprecation functionality.
  • #internal For changesets that need to be excluded from the final changelog.
  • #nops For any feature that is NOP facing and needs to be in the official Release Notes for the release.
  • #removed For any functionality/config that is removed.
  • #updated For any functionality that is updated.
  • #wip For any change that is not ready yet and external communication about it should be held off till it is feature complete.

@cl-sonarqube-production
Copy link

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@Unheilbar Unheilbar marked this pull request as ready for review October 17, 2025 21:16
@Unheilbar Unheilbar requested review from a team as code owners October 17, 2025 21:16
return nil, callErr
}

callMsg := ethereum.CallMsg{
Copy link
Collaborator

Choose a reason for hiding this comment

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

can we add a test for that? (also with the comment from JIRA why we do that)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I added a summary to the PR description.
What would the test look like? We have higher level tests that use method read under the hood.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Judging by the JIRA, it seems essential that the From: is not set. Hence, it seems natural to enforce this behavior in tests (currently, no test would fail if someone introduces From: back)

Copy link
Collaborator Author

@Unheilbar Unheilbar Oct 18, 2025

Choose a reason for hiding this comment

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

method.GetLatestValue is the only place where From can be set; that's where CallMsg is formed. I agree the test case would be reasonable if the scope of setting CallMsg.From were broader.
p.s. Also it's essential for the From not to be a contract address, we don't necessary need to enforce empty From via tests.

Copy link
Collaborator

@pavel-raykov pavel-raykov Oct 18, 2025

Choose a reason for hiding this comment

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

In the tests here

tester := &simpleTester{returnVal: big.NewInt(42), internalType: test}
we essentially construct a chain_reader with a mocked client. Would it be possible to return the mocked client and insert an assertion that CallContract is called with not a contract address?

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.

3 participants