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

Clean up the VMTracer and trace events interface in TS #5429

Merged
merged 6 commits into from
Jun 28, 2024

Conversation

Xanewok
Copy link
Contributor

@Xanewok Xanewok commented Jun 25, 2024

  • Because this PR includes a bug fix, relevant tests have been included.
  • Because this PR includes a new feature, the change was previously discussed on an Issue or with someone from the team.
  • I didn't do anything of this.

Rather than defining the callbacks at the provider instantiation time for the entire lifetime of the provider, this allows for a more granular control of injecting the trace event listener (VMTracer), thus simplifying how the information flows. In the test logic, we no longer tightly couple two classes but have to keep them side by side and we can stop observing the EVM if needed, without paying the runtime cost.

While technically it's a standalone improvement, the NomicFoundation/edr#531 can nicely build on top if it as it will also allow us to conveniently observe the trace whenever needed all at once in Rust (with the Rust port of VmTracer in that PR); it also removes some dead code.

Xanewok added 5 commits June 25, 2024 12:01
This gives a more granular access and doesn't require the callers to
necessarily be concerned with details they might not be interested in.
These are already included in `BaseMessageTrace`.
@Xanewok Xanewok requested a review from a team June 25, 2024 10:14
Copy link

changeset-bot bot commented Jun 25, 2024

⚠️ No Changeset found

Latest commit: 2fe2cff

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

vercel bot commented Jun 25, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
hardhat ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 28, 2024 9:23pm

@Xanewok Xanewok added the no changeset needed This PR doesn't require a changeset label Jun 25, 2024
Copy link
Member

@Wodann Wodann left a comment

Choose a reason for hiding this comment

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

LGTM!

One nitpick

@kanej kanej removed their assignment Jun 27, 2024
@Xanewok Xanewok merged commit ca57894 into main Jun 28, 2024
88 checks passed
Copy link

gitpoap-bot bot commented Jun 28, 2024

Congrats, your important contribution to this open-source project has earned you a GitPOAP!

GitPOAP: 2024 Hardhat Contributor:

GitPOAP: 2024 Hardhat Contributor GitPOAP Badge

Head to gitpoap.io & connect your GitHub account to mint!

Learn more about GitPOAPs here.

@Xanewok Xanewok deleted the refactor/vm-tracer-cleanup branch June 28, 2024 21:59
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
no changeset needed This PR doesn't require a changeset status:triaging
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants