-
Notifications
You must be signed in to change notification settings - Fork 10
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
Fix zkEVM blockchains and add Linea blockchains #42
Conversation
src/constants.ts
Outdated
@@ -97,13 +101,15 @@ const blockchainNetworkMap = { | |||
[`${Blockchain.Polygon}:${NetworkId.Main}`]: 0b0001_0000 | 0b0000_0001, | |||
[`${Blockchain.Polygon}:${NetworkId.Mumbai}`]: 0b0001_0000 | 0b0000_0010, | |||
[`${Blockchain.Polygon}:${NetworkId.Amoy}`]: 0b0001_0000 | 0b0000_0011, | |||
[`${Blockchain.Polygon}:${NetworkId.Zkevm}`]: 0b0011_0000 | 0b0000_0001, |
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.
we shouldn't change Blockchain bytes, for Polygon it's 0b0001_0000
, you need to change NetworkId flag
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.
Or we shouldn't change networkFlag
to not break anything ?
CC @vmidyllic
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.
we could set it like this 0b0001_0000 | 0b0010_0001,
so first 4 bits would be the same as other Polygon and in netwrok we will keep final version of networkFlag as it was
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.
Values should match golang ones:
{Blockchain: Polygon, NetworkID: Zkevm}: 0b0001_0000 | 0b0000_0100,
{Blockchain: Polygon, NetworkID: Cardona}: 0b0001_0000 | 0b0000_0101,
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.
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.
Fixed
Fix zkevm blockchains
Add Linea blockchains