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

Add hardhat_metadata RPC method #3382

Merged
merged 3 commits into from Nov 29, 2022
Merged

Add hardhat_metadata RPC method #3382

merged 3 commits into from Nov 29, 2022

Conversation

fvictorio
Copy link
Member

Adds a new hardhat_metadata RPC method. This method is meant to be used by other tools, like wallets or deployment systems, to get information about the instance of the network.

@changeset-bot
Copy link

changeset-bot bot commented Nov 29, 2022

🦋 Changeset detected

Latest commit: 34f6c34

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
hardhat Patch

Not sure what this means? Click here to learn what changesets are.

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

@vercel
Copy link

vercel bot commented Nov 29, 2022

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

Name Status Preview Updated
hardhat ✅ Ready (Inspect) Visit Preview Nov 29, 2022 at 6:18PM (UTC)
hardhat-storybook ✅ Ready (Inspect) Visit Preview Nov 29, 2022 at 6:18PM (UTC)

// This field is only present when Hardhat Network is forking another chain.
forkedNetwork?: {
// The chainId of the network that is being forked
chainId: number;
Copy link
Member

Choose a reason for hiding this comment

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

Should add networkId here, for consistency?

Copy link
Member Author

Choose a reason for hiding this comment

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

Removed networkId instead.

Copy link
Member

@alcuadrado alcuadrado left a comment

Choose a reason for hiding this comment

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

LGTM.

I just left a comment about fork network id, mostly to make the API more consistent.

@alcuadrado
Copy link
Member

I just left a comment about fork network id, mostly to make the API more consistent.

We decided to drop networkId instead, as it's not clearly why one would use it for. We can reintroduce it if needed.

@fvictorio fvictorio merged commit 3adb6f6 into main Nov 29, 2022
@fvictorio fvictorio deleted the hardhat-metadata branch November 29, 2022 19:58
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants