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

zk init error #12

Closed
oneforalone opened this issue Mar 24, 2023 · 7 comments
Closed

zk init error #12

oneforalone opened this issue Mar 24, 2023 · 7 comments

Comments

@oneforalone
Copy link

I'm trying to build the server from the source code on Ubuntu 20.04, but got an error while running zk init:

$ zk init

-------------------------
> Creating docker volumes
✔ Creating docker volumes done (13ms)

----------------
> Pulling images
Pulling geth     ... done
Pulling postgres ... done
✔ Pulling images done (9700ms)

----------------------
> Checking environment
✔ Checking environment done (46ms)

--------------------
> Checking git hooks
✔ Checking git hooks done (2ms)

-----------------------
> Setting up containers
zksync-era_postgres_1 is up-to-date
zksync-era_geth_1 is up-to-date
✔ Setting up containers done (386ms)

-------------------------------------
> Checkout system-contracts submodule
✔ Checkout system-contracts submodule done (25ms)

-----------------------
> Compiling JS packages
yarn install v1.22.19
[1/4] Resolving packages...
success Already up-to-date.
Done in 0.40s.
yarn run v1.22.19
$ yarn npm-run-all --parallel build:*
$ /lotus/zksync/zksync-era/node_modules/.bin/npm-run-all --parallel 'build:*'
$ yarn web3 build
$ yarn reading-tool build
$ yarn workspace zksync-web3 build
$ yarn workspace reading-tool build
$ tsc && cp -f typechain/*.d.ts build/typechain
$ tsc
Done in 5.19s.
✔ Compiling JS packages done (5944ms)

----------------------
> Compile l2 contracts
yarn run v1.22.19
$ /lotus/zksync/zksync-era/node_modules/.bin/hardhat compile
Nothing to compile
Done in 0.47s.
yarn install v1.22.19
[1/4] Resolving packages...
success Already up-to-date.
Done in 0.40s.
yarn run v1.22.19
$ /lotus/zksync/zksync-era/node_modules/.bin/hardhat compile
Nothing to compile
Done in 0.24s.
yarn run v1.22.19
error Command "preprocess" not found.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Error: Child process exited with code 1

I tried install preprocess via yarn, but the output remains the same. How can i fix it?

@oneforalone oneforalone changed the title zk init zk init error Mar 24, 2023
@MadaraAlive
Copy link

I am facing same issue

@Niet-Pham
Copy link

Niet-Pham commented Mar 29, 2023

Have you run yarn yet? and build zksync-sdk-web3, reading-tool? I think the sub module about smart contract not working

@pwnforce
Copy link

pwnforce commented Apr 4, 2023

I got the same error! is there any solution?

@shahar4
Copy link
Collaborator

shahar4 commented Apr 5, 2023

Hey! Thanks for the questions! zk init should init the git submodules, but perhaps it didn't work for you for some reason. Please try to verify that the systems contract submodule was brought in correctly, and if not init it manually.

@pwnforce
Copy link

pwnforce commented Apr 5, 2023

The problem is that in the scripts section of the package.json file, it seems that there's no "preprocess" script defined.
Could you please let me know what the preprocess script is supposed to do exactly? then we can run it manually.

@oday0311
Copy link

try this.
"preprocess": "rm -rf ./bootloader/build && yarn ts-node scripts/process.ts",

@oday0311
Copy link

also ,you can try run, git submodule init , git submodule update, first .
then after pull the submodules, the problem fix.

@shahar4 shahar4 closed this as completed Jun 2, 2023
SuccinctPaul pushed a commit to SuccinctPaul/zksync-era that referenced this issue Apr 19, 2024
StanislavBreadless added a commit that referenced this issue Dec 19, 2024
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

6 participants