diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 5a2dbdc07f..7965b516f5 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -4,8 +4,8 @@ on:
pull_request:
push:
branches:
- - staging
- - trying
+ - staging
+ - trying
jobs:
lint:
@@ -121,9 +121,6 @@ jobs:
ci_run zk test i api
ci_run zk test i api-docs
- - name: integration-zcli
- run: ci_run zk test i zcli
-
- name: integration-rust-sdk
run: ci_run zk test i rust-sdk
@@ -147,7 +144,7 @@ jobs:
run: |
echo ZKSYNC_HOME=$(pwd) >> $GITHUB_ENV
echo $(pwd)/bin >> $GITHUB_PATH
-
+
- name: start-services
run: |
docker-compose -f docker-compose-runner.yml down
@@ -234,7 +231,6 @@ jobs:
docker-compose -f docker-compose-runner.yml exec -T -e ALLOWED_PERCENT=20 -e RUST_LOG=loadnext=debug -e ZKSYNC_RPC_ADDR=http://127.0.0.2:3030 -e WEB3_URL=http://geth:8545 -e ETH_NETWORK=localhost -e MASTER_WALLET_PK=74d8b3a188f7260f67698eb44da07397a298df5427df681ef68c45b34b61f998 -e ACCOUNTS_AMOUNT=5 -e OPERATIONS_PER_ACCOUNT=5 -e MAIN_TOKEN=DAI zk ./target/release/loadnext
docker-compose -f docker-compose-runner.yml exec -T -e ZKSYNC_REST_ADDR=http://127.0.0.2:3001 zk ts-node core/tests/check-block-root-hahes.ts
-
- name: stop-server
run: |
ci_run killall zksync_server
@@ -249,22 +245,20 @@ jobs:
ci_run sleep 30
docker-compose -f docker-compose-runner.yml exec -T -e ZKSYNC_REST_ADDR=http://127.0.0.2:3001 zk ts-node core/tests/check-block-root-hahes.ts
-
- name: Show logs
if: always()
run: |
ci_run cat server.log
ci_run cat api.log
-
notify:
if: always()
name: Notify on failures
runs-on: ubuntu-latest
- needs: [lint, unit-tests, integration, circuit-tests, testkit, revert-blocks]
+ needs:
+ [lint, unit-tests, integration, circuit-tests, testkit, revert-blocks]
steps:
- -
- if: failure()
+ - if: failure()
name: Notify to Mattermost (on incidents)
uses: tferreira/matterfy@releases/v1
with:
diff --git a/.github/workflows/deploy-stage.yml b/.github/workflows/deploy-stage.yml
index d3426bffa2..a2433e3f65 100644
--- a/.github/workflows/deploy-stage.yml
+++ b/.github/workflows/deploy-stage.yml
@@ -24,7 +24,8 @@ jobs:
build-images:
name: Build and Push Docker Images
- runs-on: [self-hosted, MAIN]
+ needs: [setup]
+ runs-on: [self-hosted, ci-runner]
steps:
- uses: actions/checkout@v2
@@ -34,25 +35,28 @@ jobs:
echo CI=1 >> $GITHUB_ENV
echo $(pwd)/bin >> $GITHUB_PATH
+ - name: start-services
+ run: |
+ docker-compose -f docker-compose-runner.yml down
+ docker-compose -f docker-compose-runner.yml up -d zk postgres
+
- name: init
run: |
- cargo sqlx --version || cargo install sqlx-cli
- zk
- zk run yarn
- cp etc/tokens/{test,localhost}.json
- zk run verify-keys unpack
- zk up
- zk db basic-setup
+ ci_run zk
+ ci_run zk run yarn
+ ci_run cp etc/tokens/{test,localhost}.json
+ ci_run zk run verify-keys unpack
+ ci_run zk db basic-setup
- name: update-images
run: |
- docker login -u ${{ secrets.DOCKER_USER }} -p ${{ secrets.DOCKER_PASSWORD }}
- zk docker push rust
+ ci_run docker login -u ${{ secrets.DOCKER_USER }} -p ${{ secrets.DOCKER_PASSWORD }}
+ ci_run zk docker push rust
- name: docker-down
if: always()
run: |
- docker-compose down
+ docker-compose -f docker-compose-runner.yml down
# Reminder: when disabling the deploy stage - comment the whole job out!
deploy:
diff --git a/.gitignore b/.gitignore
index de191face4..a83a113786 100644
--- a/.gitignore
+++ b/.gitignore
@@ -46,8 +46,6 @@ go_to_env.sh
core/lib/storage/.env
-.zcli-config.json
-
# Perf/flamegraph files
perf.data*
flamegraph.svg
diff --git a/bin/zcli b/bin/zcli
deleted file mode 100755
index c793ad29e6..0000000000
--- a/bin/zcli
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/bash
-
-if [ -z "$1" ]; then
- cd $ZKSYNC_HOME
- yarn && yarn zcli build
-else
- # can't start this with yarn since it has quirks with `--` as an argument
- node -- $ZKSYNC_HOME/infrastructure/zcli/build/index.js "$@"
-fi
diff --git a/core/bin/zksync_api/src/utils/token_db_cache.rs b/core/bin/zksync_api/src/utils/token_db_cache.rs
index 3a494e356b..2d57fd5f56 100644
--- a/core/bin/zksync_api/src/utils/token_db_cache.rs
+++ b/core/bin/zksync_api/src/utils/token_db_cache.rs
@@ -22,6 +22,7 @@ impl TokenDBCache {
Self::default()
}
+ /// Performs case-insensitive token search.
pub async fn get_token(
&self,
storage: &mut StorageProcessor<'_>,
@@ -29,7 +30,8 @@ impl TokenDBCache {
) -> anyhow::Result