Questions tagged [zksync]
The zksync tag has no usage guidance.
35
questions
1
vote
1
answer
37
views
how do I get bytecode hash of a smart contract?
Below is a snippet of code I am using to compute the hashed bytecode of a contract, however this doesn't seem to work. This hash is passed to the create function of the zkSync Era ContractDeployer.sol ...
0
votes
0
answers
70
views
zkSync hardhat, I can't connect different address to contract
I have some problems when try to test my smart contract in zkSync with hardhat, I can't connect different address to contract like in ethers.js:
contract.connect(otherAddress).someFunction();
when I ...
0
votes
0
answers
72
views
Contract deploy problem in Zksync era network
Createfactory and transparentproxy have 2 contracts. I am facing some problems while deploying on zksync era network.
1- I'm using ethers version 5.7.2. When I deploy like this, I get this error "...
1
vote
1
answer
30
views
ETH from zkSYNK sent to wETH contract adress on Ethereum
Really curious if i could do something to retrive it.
I was on th WHOP website trying to pay for something and i didn t notice that i was on zkSYNK network and not on ethereum like i should have been. ...
0
votes
1
answer
79
views
Any way to view unverified contract's source code on Zksync era?
Is there any way to view source code of a unverified contract on Zksync era?
4
votes
3
answers
730
views
How to deploy smart contract on zkSync Era Testnet using Remix and MetaMask
I want to use the zkSync Era Testnet to do some testing with different smart contracts. I am using Remix with MetaMask as the injected provider to deploy the contract on the testnet. The contract ...
0
votes
1
answer
20
views
Can I use zkSync contracts in other EVM compatible chains?
I want to deploy a Paymaster in Polygon. I have followed this tutorial but want to deploy to Mumbai instead of zkSync Testnet.
How can I achieve this?
0
votes
0
answers
54
views
How to verify smart-contract via function?
how to verify smart-contract via function?
I try to use this:
https://era.zksync.io/docs/api/hardhat/hardhat-zksync-verify.html#verify-smart-contract-programmatically. My code:
await hre.run("...
0
votes
0
answers
57
views
ethers.getContractAt equivalent for zksync ethers
What's the euqivalent of ethers.getcontractAt() for the zkSync hardhat ethers?
0
votes
0
answers
50
views
From web3/Javascript to zkSync-web3/Typescript
I am trying to port some javascript tests targeting the Ethereum mainnet to the new zkSync testnet. This was not a problem with my standard javascript hardhat testing. Moving to typescript/zkSync, I ...
0
votes
1
answer
49
views
Zksync USDC Events
I'm trying to interpret the tx
https://explorer.zksync.io/tx/0x97ab638ce8646f058c9fdafa1d30357a4ed9ecb2c5cb0976e60d897a425ffe83#eventlog
First log event's data value is 426912250000000. The USDC ...
2
votes
0
answers
14
views
Difference between zk-rollups and nocust-zkp
What is the fundamental difference between ZK-Rollup and Nocust-ZKP? Does the data availability problem still persist in Nocust-ZKP? After going through zk-sync, I felt it might be fundamentally ...
0
votes
2
answers
119
views
Differences between on zkEVM and zkSync ERA
Are polygon zkEVM and zkSync ERA somehow different? If yes then how?
2
votes
2
answers
160
views
Reading events from layer 2 blockchains
I'm planning to query a tx using a tx hash on Ethereum and get the events/logs to find out the recipient and sender of the ETH.
Is it possible to do so for L2 blockchains like Optimism, ZkSync, ...
3
votes
1
answer
305
views
zkSync-Era Paymaster, trying to access the contract method that is being called
Here is a basic example, where I'm calling a method on myContract and using a Paymaster:
await myContract.myMethod(
myArgs,
{
customData: {
paymasterParams: paymasterParams,
...
2
votes
2
answers
1k
views
How to transfer dai for eth with syncswap api with ethers.js
Hi,I had referred to this article and now I want to test swap dai to eth with syncswap api.
But I also get the insufficient funds error, actually, there's enough eth and dai in the wallet.
//balances
...
3
votes
1
answer
610
views
Failed to get EIP-1559 fees error when deploying to ZkEVM polygon using Foundry
I have this error
Failed to get EIP-1559 fees
after running this command
forge script script/BricksCore.s.sol:BricksCoreScript --rpc-url $POLYGON_ZKEVM_RPC_URL --broadcast
My script :
contract ...
1
vote
1
answer
39
views
Help, my usdcs are lost in genosis safe wallet :)
My USDCs were in the Genosys safe wallet, and I connected the Genosys to Orbiter and bridged from Optimism to Zksync. But now I found out that Ginosys wallet doesn't have ZkSync network 😐 I mean, ...
5
votes
2
answers
97
views
zK learning, don't know where to start
I am thinking of learning zK (don't know where to start).
If someone with experience could point to the best resources to learn starting from 0, that would be awesome.
It exists already advanced ...
1
vote
1
answer
252
views
Compiler error: Stack too deep
I am getting this error when trying to deploy my smart contract using zkSync but on a different chain (Polygon Mumbai):
CompilerError: Stack too deep. Try compiling with `--via-ir` (cli) or the ...
1
vote
1
answer
66
views
Compilation is successful but getting bytecode = "0x"
I am trying to compile this very simple smart contract but I am getting its bytecode = "0x":
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;
import "@openzeppelin/...
1
vote
1
answer
1k
views
Error when trying to deploy a smart contract using deploy-zksync
I am getting the following error after running yarn hardhat deploy-zksync:
Running deploy script for the Greeter contract
An unexpected error occurred:
Error: Bytecode length in 32-byte words must be ...
0
votes
1
answer
192
views
What is the format of the private key required to deploy using deploy-zksync?
I am trying to deploy a very basic smart contract using zkSync. This is the code, from they docs:
deploy.ts
import { Wallet, utils } from "zksync-web3";
import * as ethers from "ethers&...
0
votes
2
answers
86
views
Is it possible to use zkSync in Polygon Mumbai?
I am setting up a project using zkSync and I am seeing that, in the hardhat.config.ts file, the supported network is zkSyncTestnet.
hardhat.config.ts
import "@matterlabs/hardhat-zksync-deploy&...
2
votes
0
answers
51
views
Decrypting a message using smart contract
Is this possible to send a message from address A to address B on Ethereum (or another type of blockchain), and it is so that address B can't open the message, unless a smart contract permits it ...
1
vote
0
answers
106
views
How to code a zk roll-up in Solidity smart contracts?
Zksync is a protocol that recently enabled its layer-2 technology to directly admit layer-1 Solidity code for deploying on Zksync.
Aren't zero-knowledge proofs difficult to code using Solidity ...
3
votes
4
answers
466
views
Account Abstraction still requires EOA signatures?
I was under the impression that with account abstraction, I would be able to directly initiate smart contract calls without an EOA. However, after reading through zkSync's Account Abstraction example, ...
0
votes
3
answers
6k
views
How to mint Dai to Goerli testnet wallet?
Trying to get lots of Dai (need like 300,000+) on Goerli to transfer to zksync alpha testnet.
When I try to just directly mint to my wallet's address on etherscan using the contract web interface, ...
4
votes
2
answers
45
views
Is there ever going to be some kind of parallelism in Ethereum or any L2?
Suppose I have a long array of values:
x = [1, 2, 3, ..., N] # shape [N, ] array
and a function
def f(x):
return x ** 2
then I'd do something like (similar to python's multiprocessing)
with ...
1
vote
0
answers
38
views
Is zk rollup unsecure?
We all know that zk rollup uses zk-snark to prove the state transition is valid.
But, now consider that if a malicious relayer creats a proof using incomplete transactions in a batch (e.g. relayer ...
1
vote
0
answers
40
views
What part of zk blockchain is private?
What part of a ZK blockchain is private?
Let's say for example starknet or zksync, both of them use ZK technology.
If I execute a transaction and I send a native coin (none of them have it yet) ...
2
votes
0
answers
42
views
What is the role of a circuit in zero knowledge rollups
I am a student currently pursuing my bachelors degree in technology, for my final year project. I am trying to create a zk-rollup poc for nfts, I have came across different implementation of rollup ...
0
votes
1
answer
79
views
How is circuit integrity of ZK-rollups checked by the L1 contract?
TL;DR: what prevents an evil party forge a new evil operation (say mint 100 ETH for some account) and prove that the evil operation is executed correctly to the Layer 1 verifier contract?
I am ...
1
vote
0
answers
73
views
Where can I find code of zkEVM (from zkSync)? [closed]
from https://zksync.io/zkevm/#what-is-zkevm-and-why-is-this-a-big-deal
zkEVM is a virtual machine that executes smart contracts in a way that is compatible with zero-knowledge proof computation.
...
2
votes
0
answers
122
views
Are there Ethereum Level 2 Rollup scaling solutions that support ERC-1155?
I've been doing my research on Level 2 Scaling solutions in general and docs are generally pretty lacking in detail. Usually, they just state general ideas and I'm looking for examples and concrete ...