Skip to content

Commit

Permalink
Merge branch 'matter-labs:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
CrytoInsight authored Dec 7, 2023
2 parents 7b870f0 + dd9b308 commit 3d54507
Show file tree
Hide file tree
Showing 828 changed files with 23,712 additions and 8,728 deletions.
2 changes: 1 addition & 1 deletion .githooks/pre-commit
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ RED='\033[0;31m'
NC='\033[0m' # No Color

# Check that Rust formatting rules are not violated.
function check_fmt {
check_fmt () {
if ! cargo fmt -- --check; then
echo -e "${RED}Commit error!${NC}"
echo "Please format the code via 'cargo fmt', cannot commit unformatted code"
Expand Down
10 changes: 8 additions & 2 deletions .githooks/pre-push
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash
#
# Pre-push hook verifying that inappropriate code will not be pushed.

Expand All @@ -8,7 +8,13 @@ NC='\033[0m' # No Color

# Check that prettier formatting rules are not violated.
if ! zk fmt --check; then
echo -e "${RED}Commit error!${NC}"
echo -e "${RED}Push error!${NC}"
echo "Please format the code via 'zk fmt', cannot push unformatted code"
exit 1
fi

if ! zk db check-sqlx-data; then
echo -e "${RED}Push error!${NC}"
echo "Please update sqlx-data.json via 'zk db setup', cannot push invalid sqlx-data.json file"
exit 1
fi
1 change: 1 addition & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@
- [ ] Tests for the changes have been added / updated.
- [ ] Documentation comments have been added / updated.
- [ ] Code has been formatted via `zk fmt` and `zk lint`.
- [ ] Spellcheck has been run via `cargo spellcheck --cfg=./spellcheck/era.cfg --code 1`.
4 changes: 2 additions & 2 deletions .github/release-please/manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"sdk/zksync-rs": "0.4.0",
"core": "17.1.0",
"prover": "9.0.0"
"core": "18.6.1",
"prover": "10.0.0"
}
4 changes: 2 additions & 2 deletions .github/workflows/build-core-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ jobs:
DOCKER_ACTION: ${{ inputs.action }}
COMPONENT: ${{ matrix.component }}
run: |
ci_run rustup default nightly-2023-07-21
ci_run zk docker $DOCKER_ACTION $COMPONENT -- --public
ci_run rustup default nightly-2023-08-21
ci_run zk docker $DOCKER_ACTION $COMPONENT
- name: Show sccache stats
if: always()
run: |
Expand Down
11 changes: 1 addition & 10 deletions .github/workflows/build-docker-from-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,7 @@ jobs:
- name: Generate outputs with Prover FRI setup data keys IDs
id: extract-prover-fri-setup-key-ids
run: |
declare -A json_files=(
["cpu"]="setup-data-cpu-keys.json"
["gpu"]="setup-data-gpu-keys.json"
)
for type in "${!json_files[@]}"; do
file=${json_files[$type]}
value=$(jq -r '.us' "./prover/$file")
short_sha=$(echo $value | sed 's|gs://matterlabs-setup-data-us/\(.*\)/|\1|')
echo "${type}_short_commit_sha=$short_sha" >> $GITHUB_OUTPUT
done
./prover/extract-setup-data-keys.sh >> $GITHUB_OUTPUT
build-push-core-images:
name: Build and push image
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/check-spelling.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Check Spelling

on:
push:
branches:
- main
pull_request:
merge_group:

env:
CARGO_TERM_COLOR: always

jobs:
spellcheck:
runs-on: ubuntu-latest
steps:
- name: Install cargo-spellcheck
uses: taiki-e/install-action@v2
with:
tool: cargo-spellcheck

- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4

- name: Run cargo-spellcheck
run: cargo spellcheck --cfg=./spellcheck/era.cfg --code 1
62 changes: 31 additions & 31 deletions .github/workflows/ci-core-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,25 +113,25 @@ jobs:
run: |
sudo apt update && sudo apt install wget -y
mkdir -p $(pwd)/etc/solc-bin/0.8.21
wget https://github.com/ethereum/solc-bin/raw/gh-pages/linux-amd64/solc-linux-amd64-v0.8.21%2Bcommit.d9974bed
mv solc-linux-amd64-v0.8.21+commit.d9974bed $(pwd)/etc/solc-bin/0.8.21/solc
chmod +x $(pwd)/etc/solc-bin/0.8.21/solc
mkdir -p $(pwd)/etc/zksolc-bin/v1.3.16
wget https://github.com/matter-labs/zksolc-bin/raw/main/linux-amd64/zksolc-linux-amd64-musl-v1.3.16
mv zksolc-linux-amd64-musl-v1.3.16 $(pwd)/etc/zksolc-bin/v1.3.16/zksolc
chmod +x $(pwd)/etc/zksolc-bin/v1.3.16/zksolc
mkdir -p $(pwd)/etc/vyper-bin/0.3.3
wget -O vyper0.3.3 https://github.com/vyperlang/vyper/releases/download/v0.3.3/vyper.0.3.3%2Bcommit.48e326f0.linux
mv vyper0.3.3 $(pwd)/etc/vyper-bin/0.3.3/vyper
chmod +x $(pwd)/etc/vyper-bin/0.3.3/vyper
mkdir -p $(pwd)/etc/zkvyper-bin/v1.3.11
wget https://github.com/matter-labs/zkvyper-bin/raw/main/linux-amd64/zkvyper-linux-amd64-musl-v1.3.11
mv zkvyper-linux-amd64-musl-v1.3.11 $(pwd)/etc/zkvyper-bin/v1.3.11/zkvyper
chmod +x $(pwd)/etc/zkvyper-bin/v1.3.11/zkvyper
mkdir -p $(pwd)/etc/solc-bin/0.8.23
wget https://github.com/ethereum/solc-bin/raw/gh-pages/linux-amd64/solc-linux-amd64-v0.8.23%2Bcommit.f704f362
mv solc-linux-amd64-v0.8.23+commit.f704f362 $(pwd)/etc/solc-bin/0.8.23/solc
chmod +x $(pwd)/etc/solc-bin/0.8.23/solc
mkdir -p $(pwd)/etc/zksolc-bin/v1.3.17
wget https://github.com/matter-labs/zksolc-bin/raw/main/linux-amd64/zksolc-linux-amd64-musl-v1.3.17
mv zksolc-linux-amd64-musl-v1.3.17 $(pwd)/etc/zksolc-bin/v1.3.17/zksolc
chmod +x $(pwd)/etc/zksolc-bin/v1.3.17/zksolc
mkdir -p $(pwd)/etc/vyper-bin/0.3.10
wget -O vyper0.3.10 https://github.com/vyperlang/vyper/releases/download/v0.3.10/vyper.0.3.10%2Bcommit.91361694.linux
mv vyper0.3.10 $(pwd)/etc/vyper-bin/0.3.10/vyper
chmod +x $(pwd)/etc/vyper-bin/0.3.10/vyper
mkdir -p $(pwd)/etc/zkvyper-bin/v1.3.13
wget https://github.com/matter-labs/zkvyper-bin/raw/main/linux-amd64/zkvyper-linux-amd64-musl-v1.3.13
mv zkvyper-linux-amd64-musl-v1.3.13 $(pwd)/etc/zkvyper-bin/v1.3.13/zkvyper
chmod +x $(pwd)/etc/zkvyper-bin/v1.3.13/zkvyper
- name: Start services
run: |
Expand Down Expand Up @@ -211,20 +211,20 @@ jobs:
run: |
sudo apt update && sudo apt install wget -y
mkdir -p $(pwd)/etc/solc-bin/0.8.21
wget https://github.com/ethereum/solc-bin/raw/gh-pages/linux-amd64/solc-linux-amd64-v0.8.21%2Bcommit.d9974bed
mv solc-linux-amd64-v0.8.21+commit.d9974bed $(pwd)/etc/solc-bin/0.8.21/solc
chmod +x $(pwd)/etc/solc-bin/0.8.21/solc
mkdir -p $(pwd)/etc/solc-bin/0.8.23
wget https://github.com/ethereum/solc-bin/raw/gh-pages/linux-amd64/solc-linux-amd64-v0.8.23%2Bcommit.f704f362
mv solc-linux-amd64-v0.8.23+commit.f704f362 $(pwd)/etc/solc-bin/0.8.23/solc
chmod +x $(pwd)/etc/solc-bin/0.8.23/solc
mkdir -p $(pwd)/etc/zksolc-bin/v1.3.16
wget https://github.com/matter-labs/zksolc-bin/raw/main/linux-amd64/zksolc-linux-amd64-musl-v1.3.16
mv zksolc-linux-amd64-musl-v1.3.16 $(pwd)/etc/zksolc-bin/v1.3.16/zksolc
chmod +x $(pwd)/etc/zksolc-bin/v1.3.16/zksolc
mkdir -p $(pwd)/etc/zksolc-bin/v1.3.17
wget https://github.com/matter-labs/zksolc-bin/raw/main/linux-amd64/zksolc-linux-amd64-musl-v1.3.17
mv zksolc-linux-amd64-musl-v1.3.17 $(pwd)/etc/zksolc-bin/v1.3.17/zksolc
chmod +x $(pwd)/etc/zksolc-bin/v1.3.17/zksolc
mkdir -p $(pwd)/etc/vyper-bin/0.3.3
wget -O vyper0.3.3 https://github.com/vyperlang/vyper/releases/download/v0.3.3/vyper.0.3.3%2Bcommit.48e326f0.linux
mv vyper0.3.3 $(pwd)/etc/vyper-bin/0.3.3/vyper
chmod +x $(pwd)/etc/vyper-bin/0.3.3/vyper
mkdir -p $(pwd)/etc/vyper-bin/0.3.10
wget -O vyper0.3.10 https://github.com/vyperlang/vyper/releases/download/v0.3.10/vyper.0.3.10%2Bcommit.91361694.linux
mv vyper0.3.10 $(pwd)/etc/vyper-bin/0.3.10/vyper
chmod +x $(pwd)/etc/vyper-bin/0.3.10/vyper
mkdir -p $(pwd)/etc/zkvyper-bin/v1.3.11
wget https://github.com/matter-labs/zkvyper-bin/raw/main/linux-amd64/zkvyper-linux-amd64-musl-v1.3.11
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
- '!prover/CHANGELOG.md'
- '!prover/setup-data-cpu-keys.json'
- '!prover/setup-data-gpu-keys.json'
- '!prover/extract-setup-data-keys.sh'
- 'docker/prover*/**'
- '.github/workflows/build-prover-template.yml'
- '.github/workflows/ci-prover-reusable.yml'
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ on:
push:
branches:
- main
workflow_dispatch:

permissions:
contents: write
Expand Down
13 changes: 3 additions & 10 deletions .github/workflows/release-test-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ jobs:
# We don't want to be rebuilding and redeploying all the Docker images when eg. only document have changed
prover:
- prover/**
- core/lib/**
- '!core/lib/zksync_core/**'
core:
- core/**
all:
Expand Down Expand Up @@ -58,16 +60,7 @@ jobs:
- name: Generate outputs with Prover FRI setup data keys IDs
id: extract-prover-fri-setup-key-ids
run: |
declare -A json_files=(
["cpu"]="setup-data-cpu-keys.json"
["gpu"]="setup-data-gpu-keys.json"
)
for type in "${!json_files[@]}"; do
file=${json_files[$type]}
value=$(jq -r '.us' "./prover/$file")
short_sha=$(echo $value | sed 's|gs://matterlabs-setup-data-us/\(.*\)/|\1|')
echo "${type}_short_commit_sha=$short_sha" >> $GITHUB_OUTPUT
done
./prover/extract-setup-data-keys.sh >> $GITHUB_OUTPUT
build-push-core-images:
name: Build and push images
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,7 @@ cache-zk/
zksolc
verified_sources

# Hyperchain related
hyperchain-*.yml
/etc/hyperchains/prover-keys
/etc/hyperchains/artifacts
1 change: 0 additions & 1 deletion CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
* @matter-labs/era-reviewers
.github/release-please/** @RomanBrodetski @perekopskiy @Deniallugo @popzxc
**/CHANGELOG.md @RomanBrodetski @perekopskiy @Deniallugo @popzxc
CODEOWNERS @RomanBrodetski @perekopskiy @Deniallugo @popzxc
Expand Down
Loading

0 comments on commit 3d54507

Please sign in to comment.