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

feat: add support for js tracer to geth trace, fix different return types #2064

Merged
merged 3 commits into from
Jan 31, 2023

Conversation

Vid201
Copy link
Contributor

@Vid201 Vid201 commented Jan 19, 2023

Motivation

Geth debug tracing API accepts custom JavaScript tracers.

Solution

Added support for the additional tracer.

Tracing API returns different things based on the used tracer type.

PR Checklist

  • Added Tests
  • Added Documentation
  • Updated the changelog
  • Breaking changes

Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

ty, only a few nits

ethers-core/src/types/trace/geth.rs Outdated Show resolved Hide resolved
ethers-core/src/types/trace/geth.rs Outdated Show resolved Hide resolved
ethers-core/src/types/trace/geth.rs Outdated Show resolved Hide resolved
ethers-core/src/types/trace/geth.rs Outdated Show resolved Hide resolved
ethers-core/src/types/trace/geth.rs Outdated Show resolved Hide resolved
@Vid201
Copy link
Contributor Author

Vid201 commented Jan 29, 2023

ty, only a few nits

@mattsse Made the changes, thanks for the review

@Vid201 Vid201 requested a review from mattsse January 29, 2023 18:42
Copy link
Owner

@gakonst gakonst left a comment

Choose a reason for hiding this comment

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

lgtm

@gakonst gakonst merged commit 7e7f904 into gakonst:master Jan 31, 2023
#[derive(Debug, Clone, Default, PartialEq, Eq, Serialize, Deserialize)]
pub struct CallFrame {
#[serde(rename = "type")]
pub typ: String,
Copy link
Contributor

Choose a reason for hiding this comment

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

@Vid201 Why use typ instead of type ;)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@KuTuGu AFAIK type is a keyword in Rust and cannot be used for variable/property name.

@Vid201 Vid201 deleted the feat/geth_js_tracer branch June 15, 2023 21:02
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.

4 participants