Replies: 1 comment 3 replies
-
Hello @Tarreef, Foundry script doesn't work well with zksync you should try to deploy with Just more context when you deploy on chain like Ethereum your deployment bytecode is sent to the zero address and that is how the EVM knows that your transaction is meant to deploy a contract, This exactly how foundry script work for deploying contract, But for zksync when you want to deploy a contract you send your contract bytecode to a deployer contract on the zksync chain which will then deploy your contract. So when you use Foundry to deploy a contract on zksync chain it tries to send the deployment bytecode to address(0) which is the wrong address for contract deployment on zksync hence the error Here https://docs.zksync.io/zksync-protocol/differences/contract-deployment to read more about this details |
Beta Was this translation helpful? Give feedback.
-
Just coming from Alchemy and...
I created a new app called
test_Zksync
withzksync
. with the intension to get a newrpc-url
for deployments... i ran it through the .env file. then usedbash
to deploy it...after the return key i kept getting this error...
And i'm certain i have zksync testnet funds in the

SolKey1
account.So what could be the issue spawning up this error
- server returned an error response: error code 3: Failed to serialize transaction: toAddressIsNull
Beta Was this translation helpful? Give feedback.
All reactions