Closed wshino closed 2 months ago
Hey @wshino thanks for opening the issue. Could you try the same but with --slow
flag? Zksync doesn't support batching and the lack of the flag can lead to this error. I tried your script from my end and the deployment completed successfully.
forge script script/Proxy.s.sol:ProxyScript --zksync --rpc-url $RPC_URL --broadcast -vvvv --slow
==========================
Chain 300
Estimated gas price: 0.050000001 gwei
Estimated total gas used for script: 1010640
Estimated amount required: 0.00005053200101064 ETH
==========================
##### 300
✅ [Success]Hash: 0x9fcea647d062cfaa090bd88e4a737b46793a380a216c0878b64f56629c6e6e6f
Contract Address: 0x2314d202141eB3e2838A7899a5E3dE714121BE5C
Block: 3704056
Paid: 0.00002437015 ETH (974806 gas * 0.025 gwei)
##### 300
✅ [Success]Hash: 0x1905bfb80c86ce89eeea28e4328e241ef2a9f6b8cbc96ecd33daafbf69a6372e
Contract Address: 0xB504eC969886758214f21e011D710FD92F2401c8
Block: 3704057
Paid: 0.001272628175 ETH (50905127 gas * 0.025 gwei)
✅ Sequence #1 on 300 | Total Paid: 0.001296998325 ETH (51879933 gas * avg 0.025 gwei)
==========================
ONCHAIN EXECUTION COMPLETE & SUCCESSFUL.
@Jrigada Thank you so much. I added --slow option then I've succeeded to execute the sample script.
And I completely succeeded to deploy contracts using create2 factory. relates to this issue
Component
Forge
Have you ensured that all of these are up to date?
What version of Foundry are you on?
forge 0.0.2 (f908ce4 2024-08-29T00:24:00.853692000Z)
What command(s) is the bug in?
forge script script/Proxy.s.sol:ProxyScript --zksync --rpc-url $RPC_URL --broadcast -vvvv
Operating System
macOS (Apple Silicon)
Describe the bug
When I run the deployment script that deploys ERC1967Proxy, it's failed due to the following error. Here is my sample script file. It works fine with the vanilla foundry to deploy to base sepolia.
https://gist.github.com/wshino/9b0bb6f5a20597b7b54a5ff0ac6bc7e2
In addition, I use ERC1967Proxy in my project script files since before. I believe it worked before with foundry zksync to zksync sepolia because actually I can see the txs which created contracts 1 month or 2 months ago. Why it's not working? I'd like to know how to solve this issue.