difftreelog
Merge pull request #913 from UniqueNetwork/ci-ref-v3
in: master
CI ref v3
30 files changed
.docker/Dockerfile-parachain-upgradediffbeforeafterbothno changes
.docker/Dockerfile-parachain-upgrade-datadiffbeforeafterbothno changes
.docker/Dockerfile-parachain-upgrade-data.j2diffbeforeafterbothno changes
.docker/Dockerfile-parachain-upgrade.j2diffbeforeafterbothno changes
.docker/Dockerfile-try-runtimediffbeforeafterbothno changes
.docker/Dockerfile-try-runtime.j2diffbeforeafterbothno changes
.docker/docker-compose.forkless-data.j2diffbeforeafterbothno changes
.docker/docker-compose.forkless-nodata.j2diffbeforeafterbothno changes
.docker/docker-compose.tmp-forkless-data.j2diffbeforeafterbothno changes
.docker/docker-compose.tmp-forkless-nodata.j2diffbeforeafterbothno changes
.docker/docker-compose.tmp-try-runtime.j2diffbeforeafterbothno changes
.docker/docker-compose.tmp-xcm-tests.j2diffbeforeafterbothno changes
.docker/docker-compose.try-runtime.j2diffbeforeafterbothno changes
.docker/docker-compose.xcm.j2diffbeforeafterbothno changes
.github/actions/prepare/action.ymldiffbeforeafterbothno changes
.github/workflows/ci-develop.ymldiffbeforeafterboth19 yarn-dev:19 yarn-dev:20 if: github.event.pull_request.draft == false # Conditional check for draft per job.20 if: github.event.pull_request.draft == false # Conditional check for draft per job.21 uses: ./.github/workflows/yarn-dev.yml21 uses: ./.github/workflows/yarn-dev.yml22 secrets: inherit 222323 unit-test:24 unit-test:24 if: github.event.pull_request.draft == false # Conditional check for draft per job.25 if: github.event.pull_request.draft == false # Conditional check for draft per job.25 uses: ./.github/workflows/unit-test.yml26 uses: ./.github/workflows/unit-test.yml27 secrets: inherit 262827 canary:29 canary:28 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'canary')) }} # Conditional check for draft & labels per job.30 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-canary')) }} # Conditional check for draft & labels per job.29 uses: ./.github/workflows/canary.yml31 uses: ./.github/workflows/canary.yml30 secrets: inherit # pass all secrets from initial workflow to nested32 secrets: inherit # pass all secrets from initial workflow to nested313332 xcm:34 xcm:33 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'xcm')) }} # Conditional check for draft & labels per job.35 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-xcm')) }} # Conditional check for draft & labels per job.34 uses: ./.github/workflows/xcm.yml36 uses: ./.github/workflows/xcm.yml35 secrets: inherit # pass all secrets from initial workflow to nested37 secrets: inherit # pass all secrets from initial workflow to nested36 38 37 collator-selection:39 collator-selection:38 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-collator-selection')) }} # Conditional check for draft & labels per job.40 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-collator-selection')) }} # Conditional check for draft & labels per job.39 uses: ./.github/workflows/collator-selection.yml41 uses: ./.github/workflows/collator-selection.yml40 42 secrets: inherit 43 44 # forkless:45 # if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-forkless')) }} # Conditional check for draft & labels per job.46 # uses: ./.github/workflows/forkless.yml47 # secrets: inherit 4849 forkless-update-data:50 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-forkless')) }} # Conditional check for draft & labels per job. 51 uses: ./.github/workflows/forkless-update-data.yml52 secrets: inherit # pass all secrets from initial workflow to nested 5341 forkless:54 forkless-update-no-data:42 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'forkless')) }} # Conditional check for draft & labels per job.55 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-forkless')) }} # Conditional check for draft & labels per job.43 uses: ./.github/workflows/forkless.yml56 uses: ./.github/workflows/forkless-update-nodata.yml44 57 secrets: inherit # pass all secrets from initial workflow to nested 5859 try-runtime:60 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-forkless')) }} # Conditional check for draft & labels per job. 61 uses: ./.github/workflows/try-runtime.yml62 secrets: inherit # pass all secrets from initial workflow to nested 6345 node-only-update:64 node-only-update:46 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'node-only-update')) }} # Conditional check for draft & labels per job.65 if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'CI-node-only-update')) }} # Conditional check for draft & labels per job.47 uses: ./.github/workflows/node-only-update.yml66 uses: ./.github/workflows/node-only-update.yml48 67 secrets: inherit49 # integration:50 # if: ${{ (github.event.pull_request.draft == false && contains( github.event.pull_request.labels.*.name, 'integration')) }} # Conditional check for draft & labels per job.51 # uses: ./.github/workflows/integration-tests.yml526853 codestyle:69 codestyle:54 if: github.event.pull_request.draft == false # Conditional check for draft per job.70 if: github.event.pull_request.draft == false # Conditional check for draft per job.55 uses: ./.github/workflows/codestyle.yml71 uses: ./.github/workflows/codestyle.yml5672 secrets: inherit.github/workflows/codestyle.ymldiffbeforeafterboth13 steps:13 steps:14 - name: Clean Workspace14 - name: Clean Workspace15 uses: AutoModality/action-clean@v1.1.015 uses: AutoModality/action-clean@v1.1.016 - uses: actions/checkout@v316 - uses: actions/checkout@v3.1.017 with:17 with:18 ref: ${{ github.head_ref }} 18 ref: ${{ github.head_ref }} 19 - name: Install latest nightly19 - name: Install latest nightly20 uses: actions-rs/toolchain@v120 uses: dtolnay/rust-toolchain@nightly21 with:21 with:22 toolchain: nightly23 default: true24 target: wasm32-unknown-unknown22 targets: wasm32-unknown-unknown25 components: rustfmt, clippy23 components: rustfmt, clippy26 - name: Run cargo fmt24 - name: Run cargo fmt27 run: cargo fmt -- --check # In that mode it returns only exit code.25 run: cargo fmt -- --check # In that mode it returns only exit code.34 steps:32 steps:35 - name: Clean Workspace33 - name: Clean Workspace36 uses: AutoModality/action-clean@v1.1.034 uses: AutoModality/action-clean@v1.1.037 - uses: actions/checkout@v335 - uses: actions/checkout@v3.1.038 with:36 with:39 ref: ${{ github.head_ref }} 37 ref: ${{ github.head_ref }} 40 - uses: actions/setup-node@v338 - uses: actions/setup-node@v3.5.141 with:39 with:42 node-version: 1640 node-version: 1643 - name: Install modules41 - name: Install modules49 if: ${{ false }}47 if: ${{ false }}50 runs-on: [ self-hosted-ci ]48 runs-on: [ self-hosted-ci ]51 steps:49 steps:52 - uses: actions/checkout@v350 - uses: actions/checkout@v3.1.053 - name: Install substrate dependencies51 - name: Install substrate dependencies54 run: sudo apt install -y libssl-dev pkg-config libclang-dev clang protobuf-compiler52 run: sudo apt install -y libssl-dev pkg-config libclang-dev clang protobuf-compiler55 - name: Install latest nightly53 - name: Install latest nightly56 uses: actions-rs/toolchain@v154 uses: dtolnay/rust-toolchain@nightly57 with:55 with:58 toolchain: nightly59 default: true60 target: wasm32-unknown-unknown56 targets: wasm32-unknown-unknown61 components: rustfmt, clippy57 components: rustfmt, clippy62 - name: Run cargo check58 - name: Run cargo check63 run: cargo clippy -- -Dwarnings59 run: cargo clippy -- -Dwarnings.github/workflows/execution-matrix.ymldiffbeforeafterboth24 uses: AutoModality/action-clean@v1.1.024 uses: AutoModality/action-clean@v1.1.0252526 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it26 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it27 - uses: actions/checkout@v327 - uses: actions/checkout@v3.1.028 with:28 with:29 ref: ${{ github.head_ref }} #Checking out head commit29 ref: ${{ github.head_ref }} #Checking out head commit303031 - name: Read .env file31 - name: Read .env file32 uses: xom9ikk/dotenv@v232 uses: xom9ikk/dotenv@v2333334 - name: Create Execution matrix34 - name: Create Execution matrix35 uses: CertainLach/create-matrix-action@v335 uses: CertainLach/create-matrix-action@v436 id: create_matrix36 id: create_matrix37 with:37 with:38 matrix: |38 matrix: |.github/workflows/forkless-update-data.ymldiffbeforeafterboth9# A workflow run is made up of one or more jobs that can run sequentially or in parallel9# A workflow run is made up of one or more jobs that can run sequentially or in parallel10jobs:10jobs:111112 execution-marix:12 prepare-execution-marix:131314 name: Prepare execution matrix14 name: Prepare execution matrix151523 uses: AutoModality/action-clean@v1.1.023 uses: AutoModality/action-clean@v1.1.0242425 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it25 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it26 - uses: actions/checkout@v326 - uses: actions/checkout@v3.1.027 with:27 with:28 ref: ${{ github.head_ref }} #Checking out head commit28 ref: ${{ github.head_ref }} #Checking out head commit292930 - name: Read .env file30 - name: Read .env file31 uses: xom9ikk/dotenv@v231 uses: xom9ikk/dotenv@v2323233 - name: Create Execution matrix33 - name: Create Execution matrix34 uses: CertainLach/create-matrix-action@v334 uses: CertainLach/create-matrix-action@v435 id: create_matrix35 id: create_matrix36 with:36 with:37 matrix: |37 matrix: |40 network {opal}, wasm_name {opal}, mainnet_branch {${{ env.OPAL_MAINNET_BRANCH }}}, replica_from_address {${{ env.OPAL_REPLICA_FROM }}}, relay_branch {${{ env.UNIQUEWEST_MAINNET_BRANCH }}}40 network {opal}, wasm_name {opal}, mainnet_branch {${{ env.OPAL_MAINNET_BRANCH }}}, replica_from_address {${{ env.OPAL_REPLICA_FROM }}}, relay_branch {${{ env.UNIQUEWEST_MAINNET_BRANCH }}}41 network {sapphire}, wasm_name {quartz}, mainnet_branch {${{ env.SAPPHIRE_MAINNET_BRANCH }}}, replica_from_address {${{ env.SAPPHIRE_REPLICA_FROM }}}, relay_branch {${{ env.UNIQUEEAST_MAINNET_BRANCH }}}41 network {sapphire}, wasm_name {quartz}, mainnet_branch {${{ env.SAPPHIRE_MAINNET_BRANCH }}}, replica_from_address {${{ env.SAPPHIRE_REPLICA_FROM }}}, relay_branch {${{ env.UNIQUEEAST_MAINNET_BRANCH }}}4243 forkless-data-build:44 needs: prepare-execution-marix45 # The type of runner that the job will run on46 runs-on: [self-hosted-ci,large]47 timeout-minutes: 13804849 name: ${{ matrix.network }}-data-build50 strategy:51 matrix:52 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}5354 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.5556 steps:57 - name: Clean Workspace58 uses: AutoModality/action-clean@v1.1.05960 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it61 - uses: actions/checkout@v3.1.062 with:63 ref: ${{ github.head_ref }} #Checking out head commit6465 - name: Read .env file66 uses: xom9ikk/dotenv@v26768 # Prepare SHA 69 - name: Prepare SHA70 uses: ./.github/actions/prepare7172 # Build main image for FORKLESS-UPDATE-NODATA73 - name: Generate ENV related extend Dockerfile file74 uses: cuchi/jinja2-action@v1.2.075 with:76 template: .docker/Dockerfile-parachain-upgrade-data.j277 output_file: .docker/Dockerfile-parachain-upgrade-data.${{ matrix.network }}.yml78 variables: |79 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}80 NETWORK=${{ matrix.network }}81 MAINNET_BRANCH=${{ matrix.mainnet_branch }}82 WASM_NAME=${{ matrix.wasm_name }}83 POLKADOT_BUILD_BRANCH=${{ matrix.relay_branch }}84 POLKADOT_LAUNCH_BRANCH=${{ env.POLKADOT_LAUNCH_BRANCH }}85 REPLICA_FROM=${{ matrix.replica_from_address }}8687 - name: Show build configuration88 run: cat .docker/Dockerfile-parachain-upgrade-data.${{ matrix.network }}.yml8990 - name: Generate launch-config-forkless-data.json91 uses: cuchi/jinja2-action@v1.2.092 with:93 template: .docker/forkless-config/launch-config-forkless-data.j294 output_file: .docker/forkless-config/launch-config-forkless-data.json95 variables: |96 WASM_NAME=${{ matrix.wasm_name }}97 RELAY_CHAIN_TYPE=${{ env.RELAY_CHAIN_TYPE }}98 REPLICA_FROM=${{ matrix.replica_from_address }} 99100 - name: Show launch-config-forkless configuration101 run: cat .docker/forkless-config/launch-config-forkless-data.json102103 - name: Run find-and-replace to remove slashes from branch name104 uses: mad9000/actions-find-and-replace-string@4105 id: branchname106 with:107 source: ${{ github.head_ref }}108 find: '/'109 replace: '-'110111 - name: Set build SHA112 shell: bash113 run: |114 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV115116 - name: Build the stack117 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-parachain-upgrade-data.${{ matrix.network }}.yml --tag uniquenetwork/ci-forkless-data-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA ../118119 - name: Log in to Docker Hub120 uses: docker/login-action@v2.1.0121 with:122 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}123 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}124125 - name: Push docker image version126 run: docker push uniquenetwork/ci-forkless-data-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA127128 - name: Remove builder cache129 if: always() # run this step always130 run: |131 docker builder prune -f132 docker system prune -f4213343 forkless-update-data:134 forkless-data-tests:44 needs: execution-marix135 needs: [prepare-execution-marix, forkless-data-build]45 # The type of runner that the job will run on136 # The type of runner that the job will run on46 runs-on: [self-hosted-ci,large]137 runs-on: [self-hosted-ci, large]13847 timeout-minutes: 1380139 timeout-minutes: 6004814049 name: ${{ matrix.network }}-data141 name: ${{ matrix.network }}-data-tests142143 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.14450 strategy:145 strategy:51 matrix:146 matrix:52 include: ${{fromJson(needs.execution-marix.outputs.matrix)}}147 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}5354 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.5514856 steps:149 steps:150 - name: Skip if pull request is in Draft151 if: github.event.pull_request.draft == true152 run: exit 115357 - name: Clean Workspace154 - name: Clean Workspace58 uses: AutoModality/action-clean@v1.1.0155 uses: AutoModality/action-clean@v1.1.05915660 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it157 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it61 - uses: actions/checkout@v3158 - uses: actions/checkout@v3.1.062 with:159 with:63 ref: ${{ github.head_ref }} #Checking out head commit160 ref: ${{ github.head_ref }} #Checking out head commit161162 - name: Prepare163 uses: ./.github/actions/prepare164165 - name: Set build SHA166 shell: bash167 run: |168 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV169170 - name: Run find-and-replace to remove slashes from branch name171 uses: mad9000/actions-find-and-replace-string@4172 id: branchname173 with:174 source: ${{ github.head_ref }}175 find: '/'176 replace: '-'6417765 - name: Read .env file178 - name: Read .env file66 uses: xom9ikk/dotenv@v2179 uses: xom9ikk/dotenv@v26718068 - name: Generate ENV related extend file for docker-compose181 - name: Generate ENV related extend file for docker-compose69 uses: cuchi/jinja2-action@v1.2.0182 uses: cuchi/jinja2-action@v1.2.070 with:183 with:71 template: .docker/docker-compose.tmp-forkless-data.j2184 template: .docker/docker-compose.forkless-data.j272 output_file: .docker/docker-compose-forkless-data.${{ matrix.network }}.yml185 output_file: .docker/docker-compose.forkless-data.${{ matrix.network }}.yml73 variables: |186 variables: |74 REPO_URL=${{ github.server_url }}/${{ github.repository }}.git187 NETWORK=${{ matrix.network }}75 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}188 BUILD_TAG=${{ steps.branchname.outputs.value }}-$BUILD_SHA76 POLKADOT_BUILD_BRANCH=${{ matrix.relay_branch }}77 POLKADOT_LAUNCH_BRANCH=${{ env.POLKADOT_LAUNCH_BRANCH }}78 # POLKADOT_MAINNET_BRANCH=${{ env.POLKADOT_MAINNET_BRANCH }}79 # MAINNET_TAG=${{ matrix.mainnet_tag }}80 MAINNET_BRANCH=${{ matrix.mainnet_branch }}81 NETWORK=${{ matrix.network }}82 # BRANCH=${{ github.head_ref }}83 REPLICA_FROM=${{ matrix.replica_from_address }}84 WASM_NAME=${{ matrix.wasm_name }}8518986 - name: Show build configuration190 - name: Show build configuration87 run: cat .docker/docker-compose-forkless-data.${{ matrix.network }}.yml191 run: cat .docker/docker-compose.forkless-data.${{ matrix.network }}.yml8819289 - name: Generate launch-config-forkless-data.json193 - name: Log in to Docker Hub90 uses: cuchi/jinja2-action@v1.2.0194 uses: docker/login-action@v2.1.091 with:195 with:92 template: .docker/forkless-config/launch-config-forkless-data.j2196 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}93 output_file: .docker/launch-config-forkless-data.json94 variables: |197 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}95 NETWORK=${{ matrix.network }}96 REPLICA_FROM=${{ matrix.replica_from_address }}97 WASM_NAME=${{ matrix.wasm_name}}98 RELAY_CHAIN_TYPE=${{ env.RELAY_CHAIN_TYPE }}99198100 - name: Show launch-config-forkless configuration199 - name: Build the stack101 run: cat .docker/launch-config-forkless-data.json200 run: docker-compose -f ".docker/docker-compose.forkless-data.${{ matrix.network }}.yml" up -d --remove-orphans --force-recreate --timeout 300102201103 - name: Build the stack202 - uses: actions/setup-node@v3.5.1203 with:104 run: docker-compose -f ".docker/docker-compose-forkless-data.${{ matrix.network }}.yml" up -d --build --force-recreate --timeout 300204 node-version: 16105205106 - name: Check if docker logs consist logs related to Runtime Upgrade testing.206 - name: Check if docker logs consist logs related to Runtime Upgrade testing.107 if: success()207 if: success()108 run: |208 run: |109 counter=160209 counter=160110 function check_container_status {210 function check_container_status {111 docker inspect -f {{.State.Running}} node-parachain211 docker inspect -f {{.State.Running}} forkless-data112 }212 }113 function do_docker_logs {213 function do_docker_logs {114 docker logs --details node-parachain 2>&1214 docker logs --details forkless-data 2>&1115 }215 }116 function is_started {216 function is_started {117 if [ "$(check_container_status)" == "true" ]; then217 if [ "$(check_container_status)" == "true" ]; then118 echo "Container: node-parachain RUNNING";218 echo "Container: forkless-data RUNNING";119 echo "Check Docker logs"219 echo "Check Docker logs"120 DOCKER_LOGS=$(do_docker_logs)220 DOCKER_LOGS=$(do_docker_logs)121 if [[ ${DOCKER_LOGS} = *"🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"* ]];then221 if [[ ${DOCKER_LOGS} = *"🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"* ]];then122 echo "🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"222 echo "🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"123 return 0223 return 0124 elif [[ ${DOCKER_LOGS} = *"🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"* ]];then224 elif [[ ${DOCKER_LOGS} = *"🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"* ]];then125 echo "🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"225 echo "🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"126 return 1226 return 1127 else227 else128 echo "Message not found in logs output, repeating..."228 echo "Message not found in logs output, repeating..."129 return 1229 return 1130 fi230 fi131 else231 else132 echo "Container node-parachain not RUNNING"232 echo "Container forkless-data not RUNNING"133 echo "Halting all future checks"233 echo "Halting all future checks"134 exit 1234 exit 1135 fi235 fi136 exit 0236 exit 0137 }237 }138 while ! is_started; do238 while ! is_started; do139 echo "Waiting for special message in log files "239 echo "Waiting for special message in log files "140 sleep 30s240 sleep 30s141 counter=$(( $counter - 1 ))241 counter=$(( $counter - 1 ))142 echo "Counter: $counter"242 echo "Counter: $counter"143 if [ "$counter" -gt "0" ]; then243 if [ "$counter" -gt "0" ]; then144 continue244 continue145 else245 else146 break246 break147 fi247 fi148 done248 done149 echo "Halting script"249 echo "Halting script"150 exit 0250 exit 0151 shell: bash251 shell: bash152252153 - name: Collect Docker Logs253 - name: Collect Docker Logs154 if: success() || failure()254 if: success() || failure()155 uses: jwalton/gh-docker-logs@v2.2.0255 uses: jwalton/gh-docker-logs@v2.2.1156 with:256 with:157 dest: './forkless-parachain-upgrade-data-logs.${{ matrix.features }}'257 dest: './forkless-parachain-upgrade-data-logs.${{ matrix.features }}'158 images: 'node-parachain'159258160 - name: Show Docker logs259 - name: Show Docker logs161 if: success() || failure()260 if: success() || failure()162 run: cat './forkless-parachain-upgrade-data-logs.${{ matrix.features }}/node-parachain.log'261 run: cat './forkless-parachain-upgrade-data-logs.${{ matrix.features }}/forkless-data.log'163262164 - name: Stop running containers263 - name: Stop running containers165 if: always() # run this step always264 if: always() # run this step always166 run: docker-compose -f ".docker/docker-compose-forkless-data.${{ matrix.network }}.yml" down --volumes265 run: docker-compose -f ".docker/docker-compose.forkless-data.${{ matrix.network }}.yml" down --volumes167266168 - name: Remove builder cache267 - name: Remove builder cache169 if: always() # run this step always268 if: always() # run this step always.github/workflows/forkless-update-nodata.ymldiffbeforeafterboth889# A workflow run is made up of one or more jobs that can run sequentially or in parallel9# A workflow run is made up of one or more jobs that can run sequentially or in parallel10jobs:10jobs:11 execution-marix:11 prepare-execution-marix:121213 name: Prepare execution matrix13 name: Prepare execution matrix141422 uses: AutoModality/action-clean@v1.1.022 uses: AutoModality/action-clean@v1.1.0232324 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it24 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it25 - uses: actions/checkout@v325 - uses: actions/checkout@v3.1.026 with:26 with:27 ref: ${{ github.head_ref }} #Checking out head commit27 ref: ${{ github.head_ref }} #Checking out head commit282829 - name: Read .env file29 - name: Read .env file30 uses: xom9ikk/dotenv@v230 uses: xom9ikk/dotenv@v2313132 - name: Create Execution matrix32 - name: Create Execution matrix33 uses: CertainLach/create-matrix-action@v333 uses: CertainLach/create-matrix-action@v434 id: create_matrix34 id: create_matrix35 with:35 with:36 matrix: |36 matrix: |40 network {sapphire}, wasm_name {quartz}, mainnet_branch {${{ env.SAPPHIRE_MAINNET_BRANCH }}}, relay_branch {${{ env.UNIQUEEAST_MAINNET_BRANCH }}}40 network {sapphire}, wasm_name {quartz}, mainnet_branch {${{ env.SAPPHIRE_MAINNET_BRANCH }}}, relay_branch {${{ env.UNIQUEEAST_MAINNET_BRANCH }}}414243 forkless-nodata-build:44 needs: prepare-execution-marix45 # The type of runner that the job will run on46 runs-on: [self-hosted-ci,large]4748 timeout-minutes: 13804950 name: ${{ matrix.network }}-nodata-build5152 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.5354 strategy:55 matrix:56 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}5758 steps:59 - name: Clean Workspace60 uses: AutoModality/action-clean@v1.1.06162 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it63 - uses: actions/checkout@v3.1.064 with:65 ref: ${{ github.head_ref }} #Checking out head commit6667 - name: Read .env file68 uses: xom9ikk/dotenv@v26970 # Prepare SHA 71 - name: Prepare SHA72 uses: ./.github/actions/prepare7374 - name: Log in to Docker Hub75 uses: docker/login-action@v2.1.076 with:77 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}78 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}7980 # Build main image for FORKLESS-UPDATE-NODATA81 - name: Generate ENV related extend Dockerfile file82 uses: cuchi/jinja2-action@v1.2.083 with:84 template: .docker/Dockerfile-parachain-upgrade.j285 output_file: .docker/Dockerfile-parachain-upgrade.${{ matrix.network }}.yml86 variables: |87 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}88 NETWORK=${{ matrix.network }}89 MAINNET_BRANCH=${{ matrix.mainnet_branch }}90 WASM_NAME=${{ matrix.wasm_name }}91 POLKADOT_BUILD_BRANCH=${{ matrix.relay_branch }}92 POLKADOT_LAUNCH_BRANCH=${{ env.POLKADOT_LAUNCH_BRANCH }}9394 - name: Show build Dockerfile95 run: cat .docker/Dockerfile-parachain-upgrade.${{ matrix.network }}.yml9697 - name: Generate launch-config-forkless-nodata.json98 uses: cuchi/jinja2-action@v1.2.099 with:100 template: .docker/forkless-config/launch-config-forkless-nodata.j2101 output_file: .docker/forkless-config/launch-config-forkless-nodata.json102 variables: |103 WASM_NAME=${{ matrix.wasm_name }}104 RELAY_CHAIN_TYPE=${{ env.RELAY_CHAIN_TYPE }}105106 - name: Show launch-config-forkless configuration107 run: cat .docker/forkless-config/launch-config-forkless-nodata.json108109 - name: Run find-and-replace to remove slashes from branch name110 uses: mad9000/actions-find-and-replace-string@4111 id: branchname112 with:113 source: ${{ github.head_ref }}114 find: '/'115 replace: '-'116117 - name: Set build SHA118 shell: bash119 run: |120 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV121122 - name: Build the stack123 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-parachain-upgrade.${{ matrix.network }}.yml --tag uniquenetwork/ci-forkless-nodata-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA ../124125 - name: Push docker image version126 run: docker push uniquenetwork/ci-forkless-nodata-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA127128 - name: Remove builder cache129 if: always() # run this step always130 run: |131 docker builder prune -f132 docker system prune -f411334213443 forkless-update-nodata:135 forkless-nodata-tests:44 needs: execution-marix136 needs: [prepare-execution-marix, forkless-nodata-build]45 # The type of runner that the job will run on137 # The type of runner that the job will run on46 runs-on: [self-hosted-ci,large]138 runs-on: [self-hosted-ci, large]4713948 timeout-minutes: 1380140 timeout-minutes: 6004914150 name: ${{ matrix.network }}-nodata142 name: ${{ matrix.network }}-nodata-tests5114352 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.144 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.5314554 strategy:146 strategy:55 matrix:147 matrix:56 include: ${{fromJson(needs.execution-marix.outputs.matrix)}}148 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}5714958 steps:150 steps:151 - name: Skip if pull request is in Draft152 if: github.event.pull_request.draft == true153 run: exit 115459 - name: Clean Workspace155 - name: Clean Workspace60 uses: AutoModality/action-clean@v1.1.0156 uses: AutoModality/action-clean@v1.1.06115762 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it158 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it63 - uses: actions/checkout@v3159 - uses: actions/checkout@v3.1.064 with:160 with:65 ref: ${{ github.head_ref }} #Checking out head commit161 ref: ${{ github.head_ref }} #Checking out head commit6616267 - name: Read .env file163 - name: Prepare68 uses: xom9ikk/dotenv@v2164 uses: ./.github/actions/prepare165166 - name: Set build SHA167 shell: bash168 run: |169 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV6917070 - name: Generate ENV related extend file for docker-compose171 - name: Run find-and-replace to remove slashes from branch name71 uses: cuchi/jinja2-action@v1.2.0172 uses: mad9000/actions-find-and-replace-string@4173 id: branchname72 with:174 with:73 template: .docker/docker-compose.tmp-forkless-nodata.j2175 source: ${{ github.head_ref }}74 output_file: .docker/docker-compose.${{ matrix.network }}.yml176 find: '/'75 variables: |177 replace: '-'76 REPO_URL=${{ github.server_url }}/${{ github.repository }}.git77 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}78 POLKADOT_BUILD_BRANCH=${{ matrix.relay_branch }}79 POLKADOT_LAUNCH_BRANCH=${{ env.POLKADOT_LAUNCH_BRANCH }}80 # POLKADOT_MAINNET_BRANCH=${{ env.POLKADOT_MAINNET_BRANCH }}81 # MAINNET_TAG=${{ matrix.mainnet_tag }}82 MAINNET_BRANCH=${{ matrix.mainnet_branch }}83 NETWORK=${{ matrix.network }}84 # BRANCH=${{ github.head_ref }}85 WASM_NAME=${{ matrix.wasm_name }}8617887 - name: Show build configuration179 - name: Read .env file88 run: cat .docker/docker-compose.${{ matrix.network }}.yml180 uses: xom9ikk/dotenv@v28918190 - name: Generate launch-config-forkless-nodata.json182 - name: Generate ENV related extend file for docker-compose91 uses: cuchi/jinja2-action@v1.2.0183 uses: cuchi/jinja2-action@v1.2.092 with:184 with:93 template: .docker/forkless-config/launch-config-forkless-nodata.j2185 template: .docker/docker-compose.forkless-nodata.j294 output_file: .docker/launch-config-forkless-nodata.json186 output_file: .docker/docker-compose.forkless-nodata.${{ matrix.network }}.yml95 variables: |187 variables: |96 NETWORK=${{ matrix.network }}188 NETWORK=${{ matrix.network }}97 WASM_NAME=${{ matrix.wasm_name }}189 BUILD_TAG=${{ steps.branchname.outputs.value }}-$BUILD_SHA98 RELAY_CHAIN_TYPE=${{ env.RELAY_CHAIN_TYPE }}99190100 - name: Show launch-config-forkless configuration191 - name: Show build configuration101 run: cat .docker/launch-config-forkless-nodata.json192 run: cat .docker/docker-compose.forkless-nodata.${{ matrix.network }}.yml102193103 - uses: actions/setup-node@v3194 - name: Log in to Docker Hub195 uses: docker/login-action@v2.1.0104 with:196 with:105 node-version: 16197 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}198 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}106199107 - name: Build the stack200 - name: Build the stack108 run: docker-compose -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --force-recreate --timeout 300201 run: docker-compose -f ".docker/docker-compose.forkless-nodata.${{ matrix.network }}.yml" up -d --remove-orphans --force-recreate --timeout 300202203 - uses: actions/setup-node@v3.5.1204 with:205 node-version: 16109206110 - name: Check if docker logs consist logs related to Runtime Upgrade testing.207 - name: Check if docker logs consist logs related to Runtime Upgrade testing.111 if: success()208 if: success()112 run: |209 run: |113 counter=160210 counter=160114 function check_container_status {211 function check_container_status {115 docker inspect -f {{.State.Running}} node-parachain212 docker inspect -f {{.State.Running}} forkless-nodata116 }213 }117 function do_docker_logs {214 function do_docker_logs {118 docker logs --details node-parachain 2>&1215 docker logs --details forkless-nodata 2>&1119 }216 }120 function is_started {217 function is_started {121 if [ "$(check_container_status)" == "true" ]; then218 if [ "$(check_container_status)" == "true" ]; then122 echo "Container: node-parachain RUNNING";219 echo "Container: forkless-nodata RUNNING";123 echo "Check Docker logs"220 echo "Check Docker logs"124 DOCKER_LOGS=$(do_docker_logs)221 DOCKER_LOGS=$(do_docker_logs)125 if [[ ${DOCKER_LOGS} = *"🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"* ]];then222 if [[ ${DOCKER_LOGS} = *"🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"* ]];then126 echo "🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"223 echo "🛸 PARACHAINS' RUNTIME UPGRADE TESTING COMPLETE 🛸"127 return 0224 return 0128 elif [[ ${DOCKER_LOGS} = *"🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"* ]];then225 elif [[ ${DOCKER_LOGS} = *"🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"* ]];then129 echo "🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"226 echo "🚧 PARACHAINS' RUNTIME UPGRADE TESTING FAILED 🚧"130 return 1227 return 1131 else228 else132 echo "Message not found in logs output, repeating..."229 echo "Message not found in logs output, repeating..."133 return 1230 return 1134 fi231 fi135 else232 else136 echo "Container node-parachain not RUNNING"233 echo "Container forkless-nodata not RUNNING"137 echo "Halting all future checks"234 echo "Halting all future checks"138 exit 1235 exit 1139 fi236 fi140 exit 0237 exit 0141 }238 }142 while ! is_started; do239 while ! is_started; do143 echo "Waiting for special message in log files "240 echo "Waiting for special message in log files "144 sleep 30s241 sleep 30s145 counter=$(( $counter - 1 ))242 counter=$(( $counter - 1 ))146 echo "Counter: $counter"243 echo "Counter: $counter"147 if [ "$counter" -gt "0" ]; then244 if [ "$counter" -gt "0" ]; then148 continue245 continue149 else246 else150 break247 break151 fi248 fi152 done249 done153 echo "Halting script"250 echo "Halting script"154 exit 0251 exit 0155 shell: bash252 shell: bash156253157 - name: Collect Docker Logs254 - name: Collect Docker Logs158 if: success() || failure()255 if: success() || failure()159 uses: jwalton/gh-docker-logs@v2.2.0256 uses: jwalton/gh-docker-logs@v2.2.1160 with:257 with:161 dest: './forkless-parachain-upgrade-nodata-logs.${{ matrix.features }}'258 dest: './forkless-parachain-upgrade-nodata-logs.${{ matrix.network }}'162 images: 'node-parachain'163259164 - name: Show docker logs260 - name: Show docker logs165 if: success() || failure()261 if: success() || failure()166 run: cat './forkless-parachain-upgrade-nodata-logs.${{ matrix.features }}/node-parachain.log'262 run: cat './forkless-parachain-upgrade-nodata-logs.${{ matrix.network }}/forkless-nodata.log'167263168 - name: Run Parallel tests264 - name: Run Parallel tests169 working-directory: tests265 working-directory: tests170 run: |266 run: |171 yarn install267 yarn install172 yarn add mochawesome268 yarn add mochawesome173 node scripts/readyness.js269 ./scripts/wait_for_first_block.sh174 echo "Ready to start tests"270 echo "Ready to start tests"175 yarn polkadot-types271 yarn polkadot-types176 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}272 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}177 env:273 env:178 RPC_URL: http://127.0.0.1:9933/274 RPC_URL: http://127.0.0.1:9933/179275180 - name: Test Report Parallel276 - name: Test Report Parallel181 uses: phoenix-actions/test-reporting@v8277 uses: phoenix-actions/test-reporting@v10182 id: test-report-parallel278 id: test-report-parallel183 if: success() || failure() # run this step even if previous step failed279 if: success() || failure() # run this step even if previous step failed184 with:280 with:190 - name: Run Sequential tests286 - name: Run Sequential tests191 working-directory: tests287 working-directory: tests192 if: success() || failure()288 if: success() || failure()193 run: |289 run: |194 yarn install290 yarn install195 yarn add mochawesome291 yarn add mochawesome196 node scripts/readyness.js292 ./scripts/wait_for_first_block.sh197 echo "Ready to start tests"293 echo "Ready to start tests"198 yarn polkadot-types294 yarn polkadot-types199 NOW=$(date +%s) && yarn testSequential --reporter mochawesome --reporter-options reportFilename=test-sequential-${NOW}295 NOW=$(date +%s) && yarn testSequential --reporter mochawesome --reporter-options reportFilename=test-sequential-${NOW}200 env:296 env:201 RPC_URL: http://127.0.0.1:9933/297 RPC_URL: http://127.0.0.1:9933/202298203 - name: Test Report Sequential299 - name: Test Report Sequential204 uses: phoenix-actions/test-reporting@v8300 uses: phoenix-actions/test-reporting@v10205 id: test-report-sequential301 id: test-report-sequential206 if: success() || failure() # run this step even if previous step failed302 if: success() || failure() # run this step even if previous step failed207 with:303 with:212308213 - name: Stop running containers309 - name: Stop running containers214 if: always() # run this step always310 if: always() # run this step always215 run: docker-compose -f ".docker/docker-compose.${{ matrix.network }}.yml" down311 run: docker-compose -f ".docker/docker-compose.forkless-nodata.${{ matrix.network }}.yml" down216312217 - name: Remove builder cache313 - name: Remove builder cache218 if: always() # run this step always314 if: always() # run this step always.github/workflows/forkless.ymldiffbeforeafterboth1# Intermediate Nested Workflow for calling subworkflows as a parallel tasks.1# Intermediate Nested Workflow for calling subworkflows as a parallel tasks.223name: Nesting Forkless3# name: Nesting Forkless445on:5# on:6 workflow_call:6# workflow_call:778jobs:8# jobs:9 9 10 forkless-update-data:10# forkless-update-data:11 name: with data11# name: with data12 uses: ./.github/workflows/forkless-update-data.yml12# uses: ./.github/workflows/forkless-update-data.yml1313# secrets: inherit # pass all secrets from initial workflow to nested 14 forkless-update-no-data:1415 name: no data15# forkless-update-no-data:16 uses: ./.github/workflows/forkless-update-nodata.yml16# name: no data1717# uses: ./.github/workflows/forkless-update-nodata.yml18 try-runtime:18# secrets: inherit # pass all secrets from initial workflow to nested 19 name: try-runtime1920 uses: ./.github/workflows/try-runtime.yml20# try-runtime:21# name: try-runtime22# uses: ./.github/workflows/try-runtime.yml23# secrets: inherit # pass all secrets from initial workflow to nested 2124.github/workflows/generate-execution-matrix.ymldiffbeforeafterboth28 uses: AutoModality/action-clean@v1.1.028 uses: AutoModality/action-clean@v1.1.0292930 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it30 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it31 - uses: actions/checkout@v331 - uses: actions/checkout@v3.1.032 with:32 with:33 ref: ${{ github.head_ref }} #Checking out head commit33 ref: ${{ github.head_ref }} #Checking out head commit343435 - name: Read .env file35 - name: Read .env file36 uses: xom9ikk/dotenv@v236 uses: xom9ikk/dotenv@v2373738 - name: Create Execution matrix38 - name: Create Execution matrix39 uses: CertainLach/create-matrix-action@v339 uses: CertainLach/create-matrix-action@v440 id: create_matrix40 id: create_matrix41 with:41 with:42 matrix: |42 matrix: |.github/workflows/market-test.ymldiffbeforeafterboth36 ref: ${{ github.head_ref }} #Checking out head commit36 ref: ${{ github.head_ref }} #Checking out head commit373738 - name: Checkout Market e2e tests38 - name: Checkout Market e2e tests39 uses: actions/checkout@v339 uses: actions/checkout@v3.1.040 with:40 with:41 repository: 'UniqueNetwork/market-e2e-tests'41 repository: 'UniqueNetwork/market-e2e-tests'42 ssh-key: ${{ secrets.GH_PAT }}42 ssh-key: ${{ secrets.GH_PAT }}72 working-directory: qa-tests72 working-directory: qa-tests73 run: docker-compose -f ".docker/docker-compose.market.yml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans --force-recreate node-parachain 73 run: docker-compose -f ".docker/docker-compose.market.yml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans --force-recreate node-parachain 74 74 75 - uses: actions/setup-node@v375 - uses: actions/setup-node@v3.5.176 with:76 with:77 node-version: 16.1777 node-version: 16.17787893# working-directory: tests93# working-directory: tests94# run: |94# run: |95# yarn install95# yarn install96# node scripts/readyness.js96# ./scripts/wait_for_first_block.sh97# echo "Ready to start tests"97# echo "Ready to start tests"98# env:98# env:99# RPC_URL: http://127.0.0.1:9933/99# RPC_URL: http://127.0.0.1:9933/.github/workflows/node-only-update.ymldiffbeforeafterboth25 uses: AutoModality/action-clean@v1.1.025 uses: AutoModality/action-clean@v1.1.0262627 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it27 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it28 - uses: actions/checkout@v328 - uses: actions/checkout@v3.1.029 with:29 with:30 ref: ${{ github.head_ref }} #Checking out head commit30 ref: ${{ github.head_ref }} #Checking out head commit313132 - name: Read .env file32 - name: Read .env file33 uses: xom9ikk/dotenv@v233 uses: xom9ikk/dotenv@v2343435 - name: Create Execution matrix35 - name: Create Execution matrix36 uses: CertainLach/create-matrix-action@v336 uses: CertainLach/create-matrix-action@v437 id: create_matrix37 id: create_matrix38 with:38 with:39 matrix: |39 matrix: |64 uses: AutoModality/action-clean@v1.1.064 uses: AutoModality/action-clean@v1.1.0656566 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it66 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it67 - uses: actions/checkout@v367 - uses: actions/checkout@v3.1.068 with:68 with:69 ref: ${{ github.head_ref }} #Checking out head commit69 ref: ${{ github.head_ref }} #Checking out head commit7070104 - name: Show launch-config-forkless configuration104 - name: Show launch-config-forkless configuration105 run: cat .docker/launch-config-forkless-nodata.json105 run: cat .docker/launch-config-forkless-nodata.json106106107 - uses: actions/setup-node@v3107 - uses: actions/setup-node@v3.5.1108 with:108 with:109 node-version: 16109 node-version: 16110110166 - name: Run Parallel tests before Node Parachain upgrade166 - name: Run Parallel tests before Node Parachain upgrade167 working-directory: ${{ matrix.mainnet_branch }}/tests167 working-directory: ${{ matrix.mainnet_branch }}/tests168 if: success() || failure()168 if: success() || failure()169 run: |169 run: |170 yarn install170 yarn install171 yarn add mochawesome171 yarn add mochawesome172 node scripts/readyness.js172 ./scripts/wait_for_first_block.sh173 echo "Ready to start tests"173 echo "Ready to start tests"174 yarn polkadot-types174 yarn polkadot-types175 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}175 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}176 env:176 env:177 RPC_URL: http://127.0.0.1:9933/177 RPC_URL: http://127.0.0.1:9933/178178194 RPC_URL: http://127.0.0.1:9933/194 RPC_URL: http://127.0.0.1:9933/195195196 # - name: Upload Sequential Test Report Before Node upgrade196 # - name: Upload Sequential Test Report Before Node upgrade197 # uses: phoenix-actions/test-reporting@v8197 # uses: phoenix-actions/test-reporting@v10198 # id: test-sequential-report-before198 # id: test-sequential-report-before199 # if: success() || failure() # run this step even if previous step failed199 # if: success() || failure() # run this step even if previous step failed200 # with:200 # with:289 - name: Run Parallel tests after Node Parachain upgrade289 - name: Run Parallel tests after Node Parachain upgrade290 working-directory: ${{ matrix.mainnet_branch }}/tests290 working-directory: ${{ matrix.mainnet_branch }}/tests291 if: success() || failure() # run this step even if previous step failed291 if: success() || failure() # run this step even if previous step failed292 run: |292 run: |293 yarn install293 yarn install294 yarn add mochawesome294 yarn add mochawesome295 node scripts/readyness.js295 ./scripts/wait_for_first_block.sh296 echo "Ready to start tests"296 echo "Ready to start tests"297 yarn polkadot-types297 yarn polkadot-types298 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}298 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}299 env:299 env:300 RPC_URL: http://127.0.0.1:9933/300 RPC_URL: http://127.0.0.1:9933/301301302 #- name: Test Report Parallel After Node upgrade302 #- name: Test Report Parallel After Node upgrade303 # uses: phoenix-actions/test-reporting@v8303 # uses: phoenix-actions/test-reporting@v10304 # id: test-report-parallel-after304 # id: test-report-parallel-after305 # if: success() || failure() # run this step even if previous step failed305 # if: success() || failure() # run this step even if previous step failed306 # with:306 # with:317 RPC_URL: http://127.0.0.1:9933/317 RPC_URL: http://127.0.0.1:9933/318318319 #- name: Upload Sequential Test Report After Node upgrade319 #- name: Upload Sequential Test Report After Node upgrade320 # uses: phoenix-actions/test-reporting@v8320 # uses: phoenix-actions/test-reporting@v10321 # id: test-sequential-report-after321 # id: test-sequential-report-after322 # if: success() || failure() # run this step even if previous step failed322 # if: success() || failure() # run this step even if previous step failed323 # with:323 # with:.github/workflows/polkadot-types.ymldiffbeforeafterboth66 - name: Build the stack66 - name: Build the stack67 run: docker-compose -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans67 run: docker-compose -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans686869 - uses: actions/setup-node@v369 - uses: actions/setup-node@v3.5.170 with:70 with:71 node-version: 1671 node-version: 167272.github/workflows/testnet-build.ymldiffbeforeafterboth28 uses: AutoModality/action-clean@v1.1.028 uses: AutoModality/action-clean@v1.1.0292930 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it30 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it31 - uses: actions/checkout@v331 - uses: actions/checkout@v3.1.032 with:32 with:33 ref: ${{ github.head_ref }} #Checking out head commit33 ref: ${{ github.head_ref }} #Checking out head commit343435 - name: Read .env file35 - name: Read .env file36 uses: xom9ikk/dotenv@v236 uses: xom9ikk/dotenv@v2373738 - name: Create Execution matrix38 - name: Create Execution matrix39 uses: fabiocaccamo/create-matrix-action@v239 uses: CertainLach/create-matrix-action@v440 id: create_matrix40 id: create_matrix41 with:41 with:42 matrix: |42 matrix: |68 uses: AutoModality/action-clean@v1.1.068 uses: AutoModality/action-clean@v1.1.0696970 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it70 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it71 - uses: actions/checkout@v371 - uses: actions/checkout@v3.1.072 with:72 with:73 ref: ${{ github.head_ref }} #Checking out head commit73 ref: ${{ github.head_ref }} #Checking out head commit747495 run: cat launch-config.json95 run: cat launch-config.json969697 - name: Run find-and-replace to remove slashes from branch name97 - name: Run find-and-replace to remove slashes from branch name98 uses: mad9000/actions-find-and-replace-string@298 uses: mad9000/actions-find-and-replace-string@499 id: branchname99 id: branchname100 with:100 with:101 source: ${{ github.head_ref }}101 source: ${{ github.head_ref }}102 find: '/'102 find: '/'103 replace: '-'103 replace: '-'104104105 - name: Log in to Docker Hub105 - name: Log in to Docker Hub106 uses: docker/login-action@v2.0.0106 uses: docker/login-action@v2.1.0107 with:107 with:108 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}108 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}109 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}109 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}.github/workflows/try-runtime.ymldiffbeforeafterboth21 uses: AutoModality/action-clean@v1.1.021 uses: AutoModality/action-clean@v1.1.0222223 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it23 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it24 - uses: actions/checkout@v324 - uses: actions/checkout@v3.1.025 with:25 with:26 ref: ${{ github.head_ref }} #Checking out head commit26 ref: ${{ github.head_ref }} #Checking out head commit272728 - name: Read .env file28 - name: Read .env file29 uses: xom9ikk/dotenv@v229 uses: xom9ikk/dotenv@v2303031 - name: Create Execution matrix31 - name: Create Execution matrix32 uses: CertainLach/create-matrix-action@v332 uses: CertainLach/create-matrix-action@v433 id: create_matrix33 id: create_matrix34 with:34 with:35 matrix: |35 matrix: |38 network {quartz}, wasm_name {quartz}, replica_from_address {${{ env.QUARTZ_REPLICA_FROM }}}38 network {quartz}, wasm_name {quartz}, replica_from_address {${{ env.QUARTZ_REPLICA_FROM }}}39 network {unique}, wasm_name {unique}, replica_from_address {${{ env.UNIQUE_REPLICA_FROM }}}39 network {unique}, wasm_name {unique}, replica_from_address {${{ env.UNIQUE_REPLICA_FROM }}}4041 try-runtime-build:42 needs: prepare-execution-marix4344 # The type of runner that the job will run on45 runs-on: [self-hosted-ci]46 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.4748 name: ${{ matrix.network }}-try-runtime-build49 strategy:50 matrix:51 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}5253 steps:5455 - name: Clean Workspace56 uses: AutoModality/action-clean@v1.1.05758 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it59 - uses: actions/checkout@v3.1.060 with:61 ref: ${{ github.head_ref }} #Checking out head commit6263 # Prepare SHA 64 - name: Prepare SHA65 uses: ./.github/actions/prepare6667 - name: Read .env file68 uses: xom9ikk/dotenv@v26970 - name: Log in to Docker Hub71 uses: docker/login-action@v2.1.072 with:73 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}74 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}7576 # Build main image for TRY-RUNTIME77 - name: Generate ENV related extend Dockerfile file78 uses: cuchi/jinja2-action@v1.2.079 with:80 template: .docker/Dockerfile-try-runtime.j281 output_file: .docker/Dockerfile-try-runtime.${{ matrix.network }}.yml82 variables: |83 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}84 NETWORK=${{ matrix.network }}85 WASM_NAME=${{ matrix.wasm_name }}86 REPLICA_FROM=${{ matrix.replica_from_address }}8788 - name: Show build Dockerfile89 run: cat .docker/Dockerfile-try-runtime.${{ matrix.network }}.yml9091 - name: Run find-and-replace to remove slashes from branch name92 uses: mad9000/actions-find-and-replace-string@493 id: branchname94 with:95 source: ${{ github.head_ref }}96 find: '/'97 replace: '-'9899 - name: Set build SHA100 shell: bash101 run: |102 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV103104 - name: Build the stack105 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-try-runtime.${{ matrix.network }}.yml --tag uniquenetwork/ci-tryruntime-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA ../106107 - name: Push docker image version108 run: docker push uniquenetwork/ci-tryruntime-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA109110 - name: Remove builder cache111 if: always() # run this step always112 run: |113 docker builder prune -f114 docker system prune -f1154011641 try-runtime:117 try-runtime-tests:42 needs: prepare-execution-marix118 needs: [prepare-execution-marix, try-runtime-build]4344 # The type of runner that the job will run on119 # The type of runner that the job will run on45 runs-on: [self-hosted-ci]120 runs-on: [self-hosted-ci]121122 timeout-minutes: 600123124 name: ${{ matrix.network }}-try-runtime-tests12546 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.126 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.4712748 name: ${{ matrix.network }}-try-runtime49 strategy:128 strategy:50 matrix:129 matrix:51 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}130 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}5213153 steps:132 steps:133 - name: Skip if pull request is in Draft134 if: github.event.pull_request.draft == true135 run: exit 15413655 - name: Clean Workspace137 - name: Clean Workspace56 uses: AutoModality/action-clean@v1.1.0138 uses: AutoModality/action-clean@v1.1.05713958 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it140 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it59 - uses: actions/checkout@v3141 - uses: actions/checkout@v3.1.060 with:142 with:61 ref: ${{ github.head_ref }} #Checking out head commit143 ref: ${{ github.head_ref }} #Checking out head commit144145 - name: Prepare146 uses: ./.github/actions/prepare147148 - name: Set build SHA149 shell: bash150 run: |151 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV152153 - name: Run find-and-replace to remove slashes from branch name154 uses: mad9000/actions-find-and-replace-string@4155 id: branchname156 with:157 source: ${{ github.head_ref }}158 find: '/'159 replace: '-'6216063 - name: Read .env file161 - name: Read .env file64 uses: xom9ikk/dotenv@v2162 uses: xom9ikk/dotenv@v26516366 - name: Generate ENV related extend file for docker-compose164 - name: Generate ENV related extend file for docker-compose67 uses: cuchi/jinja2-action@v1.2.0165 uses: cuchi/jinja2-action@v1.2.068 with:166 with:69 template: .docker/docker-compose.tmp-try-runtime.j2167 template: .docker/docker-compose.try-runtime.j270 output_file: .docker/docker-compose.try-runtime.${{ matrix.network }}.yml168 output_file: .docker/docker-compose.try-runtime.${{ matrix.network }}.yml71 variables: |169 variables: |72 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}170 NETWORK=${{ matrix.network }}73 NETWORK=${{ matrix.network }}171 BUILD_TAG=${{ steps.branchname.outputs.value }}-$BUILD_SHA74 WASM_NAME=${{ matrix.wasm_name }}75 REPLICA_FROM=${{ matrix.replica_from_address }}7617277 - name: Show build configuration173 - name: Show build configuration78 run: cat .docker/docker-compose.try-runtime.${{ matrix.network }}.yml174 run: cat .docker/docker-compose.try-runtime.${{ matrix.network }}.yml175176 - uses: actions/setup-node@v3.5.1177 with:178 node-version: 16179180 - name: Log in to Docker Hub181 uses: docker/login-action@v2.1.0182 with:183 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}184 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}7918580 - name: Build the stack186 - name: Build the stack81 run: docker-compose -f ".docker/docker-compose.try-runtime.${{ matrix.network }}.yml" up --build --force-recreate --timeout 300 --remove-orphans --exit-code-from try-runtime187 run: docker-compose -f ".docker/docker-compose.try-runtime.${{ matrix.network }}.yml" up -d --remove-orphans --force-recreate --timeout 3008218883 - name: Collect Docker Logs189 - name: Collect Docker Logs84 if: success() || failure()190 if: success() || failure()85 uses: jwalton/gh-docker-logs@v2.2.0191 uses: jwalton/gh-docker-logs@v2.2.186 with:192 with:87 dest: './try-runtime-logs.${{ matrix.network }}'193 dest: './try-runtime-logs.${{ matrix.network }}'88 images: 'try-runtime'8919490 - name: Show docker logs195 - name: Show docker logs91 run: cat './try-runtime-logs.${{ matrix.network }}/try-runtime.log'196 run: cat './try-runtime-logs.${{ matrix.network }}/try-runtime.log'.github/workflows/unit-test.ymldiffbeforeafterboth26 uses: AutoModality/action-clean@v1.1.025 uses: AutoModality/action-clean@v1.1.0272628 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it27 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it29 - uses: actions/checkout@v328 - uses: actions/checkout@v3.1.030 with:29 with:31 ref: ${{ github.head_ref }} #Checking out head commit30 ref: ${{ github.head_ref }} #Checking out head commit3231.github/workflows/xcm.ymldiffbeforeafterboth28 uses: AutoModality/action-clean@v1.1.028 uses: AutoModality/action-clean@v1.1.0292930 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it30 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it31 - uses: actions/checkout@v331 - uses: actions/checkout@v3.1.032 with:32 with:33 ref: ${{ github.head_ref }} #Checking out head commit33 ref: ${{ github.head_ref }} #Checking out head commit343435 - name: Read .env file35 - name: Read .env file36 uses: xom9ikk/dotenv@v236 uses: xom9ikk/dotenv@v2373738 - name: Create Execution matrix38 - name: Create Execution matrix39 uses: fabiocaccamo/create-matrix-action@v239 uses: CertainLach/create-matrix-action@v440 id: create_matrix40 id: create_matrix41 with:41 with:42 matrix: |42 matrix: |69 uses: AutoModality/action-clean@v1.1.069 uses: AutoModality/action-clean@v1.1.0707071 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it71 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it72 - uses: actions/checkout@v372 - uses: actions/checkout@v3.1.073 with:73 with:74 ref: ${{ github.head_ref }} #Checking out head commit74 ref: ${{ github.head_ref }} #Checking out head commit7576 # Prepare SHA 77 - name: Prepare SHA78 uses: ./.github/actions/prepare757976 - name: Read .env file80 - name: Read .env file77 uses: xom9ikk/dotenv@v281 uses: xom9ikk/dotenv@v2788279 - name: Log in to Docker Hub83 - name: Log in to Docker Hub80 uses: docker/login-action@v2.0.084 uses: docker/login-action@v2.1.081 with:85 with:82 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}86 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}83 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}87 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}848885 - name: Install jq89 # Check POLKADOT version and build it if it doesn't exist in repository86 run: sudo apt install jq -y8788 # Check POLKADOT version and build it if it doesn't exist in repository89 - name: Generate ENV related extend Dockerfile file for POLKADOT90 - name: Generate ENV related extend Dockerfile file for POLKADOT90 uses: cuchi/jinja2-action@v1.2.091 uses: cuchi/jinja2-action@v1.2.091 with:92 with:251 fi251 fi252 shell: bash252 shell: bash253253254 - name: Pull chainql docker image255 run: docker pull uniquenetwork/builder-chainql:latest254256255 - name: Generate ENV related extend launch-config file257 - name: Generate ENV related extend launch-config file256 uses: cuchi/jinja2-action@v1.2.0258 uses: cuchi/jinja2-action@v1.2.0284 run: cat .docker/Dockerfile-xcm.${{ matrix.network }}.yml286 run: cat .docker/Dockerfile-xcm.${{ matrix.network }}.yml285287286 - name: Run find-and-replace to remove slashes from branch name288 - name: Run find-and-replace to remove slashes from branch name287 uses: mad9000/actions-find-and-replace-string@2289 uses: mad9000/actions-find-and-replace-string@4288 id: branchname290 id: branchname289 with:291 with:290 source: ${{ github.head_ref }}292 source: ${{ github.head_ref }}291 find: '/'293 find: '/'292 replace: '-'294 replace: '-'293295294 - name: Pull chainql docker image296 - name: Set build SHA297 shell: bash295 run: docker pull uniquenetwork/builder-chainql:latest298 run: |299 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV296300297 - name: Build the stack301 - name: Build the stack298 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-xcm.${{ matrix.network }}.yml --tag uniquenetwork/xcm-${{ matrix.network }}-testnet-local:nightly-${{ steps.branchname.outputs.value }}-${{ github.sha }} --tag uniquenetwork/xcm-${{ matrix.network }}-testnet-local:latest .302 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-xcm.${{ matrix.network }}.yml --tag uniquenetwork/ci-xcm-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA .299303300 - name: Push docker image version304 - name: Push docker image version301 run: docker push uniquenetwork/xcm-${{ matrix.network }}-testnet-local:nightly-${{ steps.branchname.outputs.value }}-${{ github.sha }}305 run: docker push uniquenetwork/ci-xcm-local:${{ matrix.network }}-${{ steps.branchname.outputs.value }}-$BUILD_SHA302303 - name: Push docker image latest304 run: docker push uniquenetwork/xcm-${{ matrix.network }}-testnet-local:latest305306306 - name: Remove builder cache307 - name: Remove builder cache307 if: always() # run this step always308 if: always() # run this step always333 uses: AutoModality/action-clean@v1.1.0334 uses: AutoModality/action-clean@v1.1.0334335335 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it336 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it336 - uses: actions/checkout@v3337 - uses: actions/checkout@v3.1.0337 with:338 with:338 ref: ${{ github.head_ref }} #Checking out head commit339 ref: ${{ github.head_ref }} #Checking out head commit340341 - name: Prepare342 uses: ./.github/actions/prepare343344 - name: Set build SHA345 shell: bash346 run: |347 echo "BUILD_SHA=${LAST_COMMIT_SHA:0:8}" >> $GITHUB_ENV348349 - name: Run find-and-replace to remove slashes from branch name350 uses: mad9000/actions-find-and-replace-string@4351 id: branchname352 with:353 source: ${{ github.head_ref }}354 find: '/'355 replace: '-'339356340 - name: Read .env file357 - name: Read .env file341 uses: xom9ikk/dotenv@v2358 uses: xom9ikk/dotenv@v2342359343 - name: Generate ENV related extend file for docker-compose360 - name: Generate ENV related extend file for docker-compose344 uses: cuchi/jinja2-action@v1.2.0361 uses: cuchi/jinja2-action@v1.2.0345 with:362 with:346 template: .docker/docker-compose.tmp-xcm-tests.j2363 template: .docker/docker-compose.xcm.j2347 output_file: .docker/docker-compose.xcm-tests.${{ matrix.network }}.yml364 output_file: .docker/docker-compose.xcm.${{ matrix.network }}.yml348 variables: |365 variables: |349 NETWORK=${{ matrix.network }}366 NETWORK=${{ matrix.network }}367 BUILD_TAG=${{ steps.branchname.outputs.value }}-$BUILD_SHA350368351 - name: Show build configuration369 - name: Show build configuration352 run: cat .docker/docker-compose.xcm-tests.${{ matrix.network }}.yml370 run: cat .docker/docker-compose.xcm.${{ matrix.network }}.yml353371354 - uses: actions/setup-node@v3372 - uses: actions/setup-node@v3.5.1355 with:373 with:356 node-version: 16374 node-version: 16375376 - name: Log in to Docker Hub377 uses: docker/login-action@v2.1.0378 with:379 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}380 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}357381358 - name: Build the stack382 - name: Build the stack359 run: docker-compose -f ".docker/docker-compose.xcm-tests.${{ matrix.network }}.yml" up -d --remove-orphans --force-recreate --timeout 300383 run: docker-compose -f ".docker/docker-compose.xcm.${{ matrix.network }}.yml" up -d --remove-orphans --force-recreate --timeout 300360384361 # 🚀 POLKADOT LAUNCH COMPLETE 🚀385 # 🚀 POLKADOT LAUNCH COMPLETE 🚀362 - name: Check if docker logs consist messages related to testing of xcm tests 386 - name: Check if docker logs consist messages related to testing of xcm tests 363 if: success()387 if: success()364 run: |388 run: |365 counter=160389 counter=160366 function check_container_status {390 function check_container_status {367 docker inspect -f {{.State.Running}} xcm-${{ matrix.network }}-testnet-local391 docker inspect -f {{.State.Running}} xcm-${{ matrix.network }}-local368 }392 }369 function do_docker_logs {393 function do_docker_logs {370 docker logs --details xcm-${{ matrix.network }}-testnet-local 2>&1394 docker logs --details xcm-${{ matrix.network }}-local 2>&1371 }395 }372 function is_started {396 function is_started {373 if [ "$(check_container_status)" == "true" ]; then397 if [ "$(check_container_status)" == "true" ]; then374 echo "Container: xcm-${{ matrix.network }}-testnet-local RUNNING";398 echo "Container: xcm-${{ matrix.network }}-local RUNNING";375 echo "Check Docker logs"399 echo "Check Docker logs"376 DOCKER_LOGS=$(do_docker_logs)400 DOCKER_LOGS=$(do_docker_logs)377 if [[ ${DOCKER_LOGS} = *"POLKADOT LAUNCH COMPLETE"* ]];then401 if [[ ${DOCKER_LOGS} = *"POLKADOT LAUNCH COMPLETE"* ]];then378 echo "🚀 POLKADOT LAUNCH COMPLETE 🚀"402 echo "🚀 POLKADOT LAUNCH COMPLETE 🚀"379 return 0403 return 0380 else404 else381 echo "Message not found in logs output, repeating..."405 echo "Message not found in logs output, repeating..."382 return 1406 return 1383 fi407 fi384 else408 else385 echo "Container xcm-${{ matrix.network }}-testnet-local NOT RUNNING"409 echo "Container xcm-${{ matrix.network }}-local NOT RUNNING"386 echo "Halting all future checks"410 echo "Halting all future checks"387 exit 1411 exit 1388 fi412 fi389 echo "something goes wrong"413 echo "something goes wrong"390 exit 1414 exit 1391 }415 }392 while ! is_started; do416 while ! is_started; do393 echo "Waiting for special message in log files "417 echo "Waiting for special message in log files "394 sleep 30s418 sleep 30s395 counter=$(( $counter - 1 ))419 counter=$(( $counter - 1 ))396 echo "Counter: $counter"420 echo "Counter: $counter"397 if [ "$counter" -gt "0" ]; then421 if [ "$counter" -gt "0" ]; then398 continue422 continue399 else423 else400 break424 break401 fi425 fi402 done426 done403 echo "Halting script"427 echo "Halting script"404 exit 0428 exit 0405 shell: bash429 shell: bash406430407 - name: Run XCM tests 431 - name: Run XCM tests 408 working-directory: tests432 working-directory: tests409 run: |433 run: |410 yarn install434 yarn install411 yarn add mochawesome435 yarn add mochawesome412 node scripts/readyness.js436 ./scripts/wait_for_first_block.sh413 echo "Ready to start tests"437 echo "Ready to start tests"414 yarn polkadot-types 438 yarn polkadot-types 415 NOW=$(date +%s) && yarn ${{ matrix.runtest }} --reporter mochawesome --reporter-options reportFilename=test-${NOW}439 NOW=$(date +%s) && yarn ${{ matrix.runtest }} --reporter mochawesome --reporter-options reportFilename=test-${NOW}416 env:440 env:417 RPC_URL: http://127.0.0.1:9933/441 RPC_URL: http://127.0.0.1:9933/418442419 - name: XCM Test Report443 - name: XCM Test Report420 uses: phoenix-actions/test-reporting@v8444 uses: phoenix-actions/test-reporting@v10421 id: test-report445 id: test-report422 if: success() || failure() # run this step even if previous step failed446 if: success() || failure() # run this step even if previous step failed423 with:447 with:428452429 - name: Show container logs453 - name: Show container logs430 if: always() # run this step always454 if: always() # run this step always431 run: docker-compose -f ".docker/docker-compose.xcm-tests.${{ matrix.network }}.yml" logs455 run: docker-compose -f ".docker/docker-compose.xcm.${{ matrix.network }}.yml" logs432456433 - name: Stop running containers457 - name: Stop running containers434 if: always() # run this step always458 if: always() # run this step always435 run: docker-compose -f ".docker/docker-compose.xcm-tests.${{ matrix.network }}.yml" down459 run: docker-compose -f ".docker/docker-compose.xcm.${{ matrix.network }}.yml" down436460437 - name: Clean Workspace461 - name: Clean Workspace438 if: always()462 if: always().github/workflows/yarn-dev.ymldiffbeforeafterboth34 uses: AutoModality/action-clean@v1.1.034 uses: AutoModality/action-clean@v1.1.0353536 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it36 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it37 - uses: actions/checkout@v337 - uses: actions/checkout@v3.1.038 with:38 with:39 ref: ${{ github.head_ref }} #Checking out head commit39 ref: ${{ github.head_ref }} #Checking out head commit404057 - name: Build the stack57 - name: Build the stack58 run: docker-compose -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans58 run: docker-compose -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans595960 - uses: actions/setup-node@v360 - uses: actions/setup-node@v3.5.161 with:61 with:62 node-version: 1662 node-version: 16636364 - name: Run tests64 - name: Run tests65 working-directory: tests65 working-directory: tests66 run: |66 run: |67 yarn install67 yarn install68 yarn add mochawesome68 yarn add mochawesome69 node scripts/readyness.js69 ./scripts/wait_for_first_block.sh70 echo "Ready to start tests"70 echo "Ready to start tests"71 yarn polkadot-types71 yarn polkadot-types72 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}72 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}73 env:73 env:74 RPC_URL: http://127.0.0.1:9933/74 RPC_URL: http://127.0.0.1:9933/757576 - name: Test Report76 - name: Test Report77 uses: phoenix-actions/test-reporting@v877 uses: phoenix-actions/test-reporting@v1078 id: test-report78 id: test-report79 if: success() || failure() # run this step even if previous step failed79 if: success() || failure() # run this step even if previous step failed80 with:80 with:98 docker system prune -f98 docker system prune -f99 docker image prune -f -a99 docker image prune -f -a100100101 # check:102 # if: always()103 # runs-on: [self-hosted-ci]104 # needs:105 # - dev_build_int_tests106107 # steps:108 # - name: Install python3109 # uses: actions/setup-python@v4110 # with:111 # python-version: '3.10'112113 # - name: Decide whether the needed jobs succeeded or failed114 # uses: re-actors/alls-green@v1.2.2115 # with:116 # jobs: ${{ toJSON(needs) }}