Skip to content

Commit

Permalink
Update tee-dev branch into polkadot v0.9.29 (#971)
Browse files Browse the repository at this point in the history
* merge tee-dev branch into dev branch (#902)

* adjust docker tag for tee-dev

* use integritee/pallets master branch

* add teeracle to tee-dev

* switch to sdk-v0.9.0-polkadot-v0.9.26 as release branch

* add back the dummy method for testing purpose

* fix make clippy

* small cleanup

* add back teeracle

* use specific branch of tee-primitives (todo:revert it)

* correctify branch for tee-primitives

* temporarily use TEE pallets master branch

* add EnsureOrigin impl and tests

* its better to place it in runtime_common

* remove the dummy extrinsic (used for testing previous)

Co-authored-by: Kailai Wang <[email protected]>
Co-authored-by: BillyWooo <[email protected]>

* 0.9.29 update (#891)

* feat: rough update to 0.9.29

* debug:temp fmt

* debug: 0.9.29 without trystate

* debug: Integration with latest try-runtime

* debug: update weight template

* debug: fmt

* debug: patch toml try-runtime

* debug: fmt

* debug: revert template non-weight part

* debug: add teeracle try-runtime

* debug: cargo lock

* fix Cargo.lock (#904)

* lift the bridge transfer restriciton and bump version (#907)

* use hash to compute the raw payload (#910)

* remove Litmus sudo (#876)

* sudo

* change Root into Root +democracy

* debug: recover chainspec rootkey

* fix clippy

* try to fix #900

* add debug log #900

* make CI tests pass after remove litmus `Sudo`

* fmt

* debug

* debug

* rococo/litentry align with litmus

* remove useless test code

Co-authored-by: Kai <[email protected]>
Co-authored-by: BillyWooo <[email protected]>
Co-authored-by: zhiming-zhong <[email protected]>

* Use rococo as dev network (#918)

* add rococo staging

* cargo update

* update README

* fix bad english

* Bump aes-gcm from `be0d6c2` to `5eb6d1a` (#925)

Bumps [aes-gcm](https://github.com/RustCrypto/AEADs) from `be0d6c2` to `5eb6d1a`.
- [Release notes](https://github.com/RustCrypto/AEADs/releases)
- [Commits](RustCrypto/AEADs@be0d6c2...5eb6d1a)

---
updated-dependencies:
- dependency-name: aes-gcm
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump scale-info from 2.2.0 to 2.3.0 (#926)

Bumps [scale-info](https://github.com/paritytech/scale-info) from 2.2.0 to 2.3.0.
- [Release notes](https://github.com/paritytech/scale-info/releases)
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md)
- [Commits](https://github.com/paritytech/scale-info/commits/v2.3.0)

---
updated-dependencies:
- dependency-name: scale-info
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Minor update (#928)

* add dwellir bootnode

* bump litmus runtime version

* cargo update

* feat: relocate remove_sudo migration code (#936)

* feat: relocate remove_sudo migration code

* debug: fmt

* debug: change staking parameter (#931)

* debug: change staking parameter

* debug: bump rococo.litentry spec version

* Use sccache in Dockerfile (#937)

* try to switch to github-runner

* use sccache in Dockerfile for self-hosted runner

* fix syntax

* download sccache

* fix path and use pre-built taplo

* intentionally change lib.rs

* intentionally update a pallet only

* try to add/stop sccache server

* minor update

* update README

* try to use rust-cache

* use /root

* use GITHUB_REF_NAME in hash-key

* I dislike github syntax

* another try

* deprecate set-output

* revert back lib.rs

* dintinguish between release and prod

* fix RUN order

* use head_ref or ref_name

Co-authored-by: BillyWooo <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: Kailai Wang <[email protected]>
Co-authored-by: BillyWooo <[email protected]>
Co-authored-by: WMQ <[email protected]>
Co-authored-by: Kai <[email protected]>
Co-authored-by: zhiming-zhong <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Loading branch information
7 people authored Nov 23, 2022
1 parent 59b698f commit c76adde
Show file tree
Hide file tree
Showing 134 changed files with 3,784 additions and 3,489 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/benchmark-machine.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
echo "Remote instance reachable now after $SECONDS seconds"
remote_ip=`aws ec2 describe-instances --filters 'Name=instance-state-name,Values=running' 'Name=instance-id,Values=${{ env.INSTANCE_ID }}' --query 'Reservations[*].Instances[*].[PublicIpAddress]' --output text`
echo "Running instances ip address: $remote_ip"
echo "::set-output name=remote_ip::$remote_ip"
echo "remote_ip=$remote_ip" >> $GITHUB_OUTPUT
# exit status should propagate through ssh
- name: Remotely benchmark machine
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/benchmark-runtime-weights.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ env:
INSTANCE_ID: ${{ secrets.BENCHMARK_INSTANCE_ID }} # remote AWS host to run benchmarking
BENCHMARK_SSH_USER: ${{ secrets.BENCHMARK_SSH_USER }}
BENCHMARK_SSH_KEYPATH: ${{ secrets.BENCHMARK_SSH_KEYPATH }}
DOCKER_BUILDKIT: 1

jobs:
## build docker image with runtime-benchmarks feature
build-docker:
Expand Down Expand Up @@ -112,7 +114,7 @@ jobs:
echo "Remote instance reachable now after $SECONDS seconds"
remote_ip=`aws ec2 describe-instances --filters 'Name=instance-state-name,Values=running' 'Name=instance-id,Values=${{ env.INSTANCE_ID }}' --query 'Reservations[*].Instances[*].[PublicIpAddress]' --output text`
echo "Running instances ip address: $remote_ip"
echo "::set-output name=remote_ip::$remote_ip"
echo "remote_ip=$remote_ip" >> $GITHUB_OUTPUT
# exit status should propagate through ssh
- name: Remotely benchmark pallets ${{ github.event.inputs.pallets }} for ${{ env.CHAIN }}
Expand Down
44 changes: 30 additions & 14 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ on:

env:
CARGO_TERM_COLOR: always
DOCKER_BUILDKIT: 1
# the branch or tag on which this workflow is triggered
# `head_ref` will only be set if the triggering event is `pull_request`
REF_VERSION: ${{ github.head_ref || github.ref_name }}

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -73,8 +77,14 @@ jobs:
- name: Run cargo fmt check
run: make fmtcheck

- name: Install taplo
run: cargo install taplo-cli --locked
- name: Install pre-built taplo
run: |
mkdir -p $HOME/.local/bin
wget -q https://github.com/tamasfe/taplo/releases/latest/download/taplo-linux-x86_64.gz
gzip -d taplo-linux-x86_64.gz
cp taplo-linux-x86_64 $HOME/.local/bin/taplo
chmod a+x $HOME/.local/bin/taplo
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Run taplo fmt check
run: make taplocheck
Expand Down Expand Up @@ -145,6 +155,10 @@ jobs:
run: |
[ -z "$(docker images --filter=dangling=true -q)" ] || docker rmi -f $(docker images --filter=dangling=true -q)
- name: Fail-fast; cancel other jobs
if: failure()
uses: andymckay/[email protected]

run-ts-tests:
runs-on: ubuntu-latest
needs: build-docker
Expand Down Expand Up @@ -204,7 +218,7 @@ jobs:
default: true

- name: Run unittests
run: cargo test --release -p pallet-* --lib
run: cargo test --locked --release -p pallet-* --lib

- name: Fail-fast; cancel other jobs
if: failure()
Expand All @@ -228,7 +242,7 @@ jobs:
default: true

- name: Run benchmarks
run: cargo test --release -p pallet-* --lib --features runtime-benchmarks
run: cargo test --locked --release -p pallet-* --lib --features runtime-benchmarks

- name: Fail-fast; cancel other jobs
if: failure()
Expand All @@ -241,16 +255,17 @@ jobs:
# This is required when setting github merge rules to protected branch,
# where you can only select one of `run-cargo-runtime-tests` and `run-cargo-runtime-tests(litmus)`.
# If you put if-check on the job level, it can't fit every possible case.
#
# Tried https://github.com/Swatinem/rust-cache too but it didn't work so well
run-cargo-runtime-tests:
runs-on: ubuntu-latest
needs: [check-cargo-fmt, check-file-change]
env:
RUST_BACKTRACE: full
RUSTC_WRAPPER: sccache
SCCACHE_CACHE_SIZE: 10G
SCCACHE_DIR: /home/runner/.cache/sccache
CARGO_INCREMENTAL: 0
strategy:
fail-fast: true
matrix:
chain:
- litmus
Expand All @@ -273,10 +288,9 @@ jobs:
# use sccache to accelerate binary compilation
# see https://www.infinyon.com/blog/2021/04/github-actions-best-practices/
- name: Install sccache
if: needs.check-file-change.outputs.src == 'true'
env:
LINK: https://github.com/mozilla/sccache/releases/download
SCCACHE_VERSION: v0.2.15
SCCACHE_VERSION: v0.3.0
run: |
SCCACHE_FILE=sccache-$SCCACHE_VERSION-x86_64-unknown-linux-musl
mkdir -p $HOME/.local/bin
Expand All @@ -287,29 +301,31 @@ jobs:
- name: Cache cargo registry
if: needs.check-file-change.outputs.src == 'true'
uses: actions/cache@v2
uses: actions/cache@v3
continue-on-error: false
with:
path: |
~/.cargo/registry
~/.cargo/git
key: cargo-${{ hashFiles('**/Cargo.lock') }}
key: cargo-${{ env.REF_VERSION }}-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
cargo-${{ env.REF_VERSION }}-
cargo-
- name: Cache sccache
if: needs.check-file-change.outputs.src == 'true'
uses: actions/cache@v2
uses: actions/cache@v3
continue-on-error: false
with:
path: /home/runner/.cache/sccache
key: sccache-${{ hashFiles('**/Cargo.lock') }}
key: sccache-${{ env.REF_VERSION }}-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
sccache-${{ env.REF_VERSION }}-
sccache-
- name: Run runtime integration tests
if: needs.check-file-change.outputs.src == 'true'
run: cargo test --release -p ${{ matrix.chain }}-parachain-runtime --lib
run: cargo test --locked --release -p ${{ matrix.chain }}-parachain-runtime --lib

- name: Print sccache stats
if: needs.check-file-change.outputs.src == 'true'
Expand Down Expand Up @@ -343,7 +359,7 @@ jobs:
docker load -i litentry-parachain.tar
- name: Dockerhub login
uses: docker/login-action@v1
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/build-docker-with-args.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ on:
default: ''
required: false

env:
DOCKER_BUILDKIT: 1

jobs:
## build docker image of client binary with args ##
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/create-release-draft.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ env:
RELEASE_TAG: ${{ github.event.inputs.release_tag }}
DIFF_TAG: ${{ github.event.inputs.diff_tag }}
GENESIS_RELEASE: ${{ github.event.inputs.genesis_release }}
DOCKER_BUILDKIT: 1

jobs:
set-release-type:
Expand All @@ -52,7 +53,7 @@ jobs:
echo "::error::Please select at least one release type."
exit 1
fi
echo "::set-output name=release_type::${release_type}"
echo "release_type=${release_type}" >> $GITHUB_OUTPUT
outputs:
release_type: ${{ steps.vars.outputs.release_type }}

Expand Down
Loading

0 comments on commit c76adde

Please sign in to comment.