-
Notifications
You must be signed in to change notification settings - Fork 5k
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
Use eth_chainId when signing transactions #3097
Conversation
Thanks @gabmontes, good to know. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you update the changelog for this and all other PRs you proposed?
@nivida Do want the changelog updated under 1.2.2? Or unreleased? |
„Unreleased“ is just the tag to label the unreleased version and the related changes. You can just extend the list of 1.2.2. @cgewecke |
@nivida Oh I just remembered something - not sure how you do this exactly but there is a nice npm utility called changelog that helps you generate a version-based changelog in one post-publication step. The output still needs to be edited etc, but it seems like a convenient way of avoiding merge conflicts when there are lots of small PRs queued up like this and they all modify the same file. |
@cgewecke Let us discuss this in an issue. :) |
* Use eth_chainId when signing transactions
Addresses #2378 and #1169 for the 1.x branch. Makes web3 conform to EIP 155 and fetch chainId via
eth_chainId
instead ofnet_version
. For ethereum public nets there's no problem here because network id == chain id. For ganache, ETC and possibly others - the two values are different.Note: these endpoints return their ids in different formats:
eth_chainId
is not documented in the JSON_RPC spec. This is a case where it would be nice to have E2E tests vs the three main clients to be sure Web3's mocked responses correspond to reality.