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(node-bindings): add methods for returning instance urls #359

Merged
merged 2 commits into from
Mar 21, 2024

Conversation

yash-atreya
Copy link
Member

@yash-atreya yash-atreya commented Mar 21, 2024

Motivation

The existing methods such as endpoint() and ws_endpoint() would return the URLs as a String. One would have to parse the String as a URL and then pass it to the provider.

Solution

Adds two methods endpoint_url() and ws_endpoint_url() which return the HTTP and WS urls respectively for both anvil and geth instances.

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

@yash-atreya
Copy link
Member Author

cc @mattsse

Copy link
Member

@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.

smol nit

crates/node-bindings/src/geth.rs Outdated Show resolved Hide resolved
Co-authored-by: Matthias Seitz <[email protected]>
@mattsse mattsse merged commit 772827f into alloy-rs:main Mar 21, 2024
16 checks passed
@yash-atreya yash-atreya deleted the anvil_instance_urls branch March 21, 2024 16:59
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.

2 participants