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

zks2.0 (EIP 1559)跨链参数修正 #1

Open
grassroadsZ opened this issue May 22, 2022 · 1 comment
Open

zks2.0 (EIP 1559)跨链参数修正 #1

grassroadsZ opened this issue May 22, 2022 · 1 comment

Comments

@grassroadsZ
Copy link

感谢大佬的详细文章,修正一点,ABI 的参数可以通过 depositETH 这个方法在js文件中 搜方法,然后对于 EIP 1559 请求构建参数的时候 只需要在原有的参数 里面加个 type 类型即可, 值固定是0x2 ,参考

    params = {

        'gas': 250000,
        'nonce': web3_instance.eth.getTransactionCount(web3_instance.toChecksumAddress(from_address)),
        'from': web3_instance.toChecksumAddress(from_address),
        'value': web3_instance.toWei(l1_amount, "ether"),
        # 'gasPrice': w3.toWei('5', 'gwei'),
        'maxFeePerGas': web3_instance.toWei(5, 'gwei'),
        'maxPriorityFeePerGas': web3_instance.toWei(5, 'gwei'),
        'chainId': 5,
        "type": "0x2",
    }
@gm365
Copy link
Owner

gm365 commented May 23, 2022

理论上,这应该属于 "goerli链" 的情况,这条链和其他的普通 EVM 兼容链稍微有点区别,甚至在 接入 w3 endpoint 时就有所体现。

我看了你链接的 issue,貌似是去年7月的情况。不清楚新版本是否已经修复这个 "0x2" 的问题了。不过我稍后打算测试下你的这个方法。

感谢指正。

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

No branches or pull requests

2 participants