Skip to content

Commit

Permalink
Update parachain dependencies to polkadot-v1.1.0 (#2936)
Browse files Browse the repository at this point in the history
* node compiles

* update fmt

* update scripts

* cargo test pass

* make clippy works

* remove log

* remove pallet-parentchain

* node compiles

* node and runtime compiles

* use 0.9.42 for worker

* fix bc worker

* try to fix tests

* comment out

* fix launch and asset config

* update rpc ports

* use new release

* fix

* use new action

* fix path

* fix path

* checkout first

* bump versions

* update lock

* uncomment

* remove it

* fix test
  • Loading branch information
Kailai-Wang authored Aug 26, 2024
1 parent 04381ca commit b66d347
Show file tree
Hide file tree
Showing 171 changed files with 5,452 additions and 6,424 deletions.
28 changes: 28 additions & 0 deletions .github/actions/disk-cleanup/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Disk cleanup
description: "Cleanup disk space"
runs:
using: composite
steps:
- name: Free up disk space
shell: bash
run: |
echo "Disk space before cleanup..."
df -h /
echo "Removing unnecessary files to free up disk space..."
# https://github.com/actions/runner-images/issues/2840#issuecomment-2272410832
sudo rm -rf \
/opt/hostedtoolcache \
/opt/google/chrome \
/opt/microsoft/msedge \
/opt/microsoft/powershell \
/opt/pipx \
/usr/lib/mono \
/usr/local/julia* \
/usr/local/lib/android \
/usr/local/lib/node_modules \
/usr/local/share/chromium \
/usr/local/share/powershell \
/usr/share/dotnet \
/usr/share/swift
echo "Disk space after cleanup..."
df -h /
12 changes: 4 additions & 8 deletions .github/workflows/benchmark-runtime-weights.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,19 +41,15 @@ jobs:
if: ${{ github.event.inputs.rebuild-docker == 'true' }}
runs-on: ubuntu-latest
steps:
- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false

- name: Checkout codes on ${{ github.ref }}
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: ./.github/actions/disk-cleanup

# try to increase usable memory
# https://github.com/actions/runner/issues/1051
- name: Set Swap Space
Expand Down
46 changes: 19 additions & 27 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -332,15 +332,11 @@ jobs:
- set-condition
- sequentialise
steps:
- uses: actions/checkout@v4

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false

- uses: actions/checkout@v4
uses: ./.github/actions/disk-cleanup

- name: Build docker image
if: needs.set-condition.outputs.rebuild_parachain == 'true'
Expand Down Expand Up @@ -380,15 +376,11 @@ jobs:
- set-condition
- sequentialise
steps:
- uses: actions/checkout@v4

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false

- uses: actions/checkout@v4
uses: ./.github/actions/disk-cleanup

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
Expand Down Expand Up @@ -524,15 +516,11 @@ jobs:
- set-condition
- sequentialise
steps:
- uses: actions/checkout@v4

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false

- uses: actions/checkout@v4
uses: ./.github/actions/disk-cleanup

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
Expand Down Expand Up @@ -695,13 +683,13 @@ jobs:
- name: Run all unittests
run: |
echo "::group::core-primitives unittest"
cargo test --locked --release -p core-primitives --lib
cargo test --locked -p core-primitives --lib
echo "::endgroup::"
echo "::group::all pallets unittest"
cargo test --locked --release -p pallet-* --lib
cargo test --locked -p pallet-* --lib
echo "::endgroup::"
echo "::group::all pallets unittest with runtime-benchmarks feature"
cargo test --locked --release -p pallet-* --lib --features=runtime-benchmarks
cargo test --locked -p pallet-* --lib --features=runtime-benchmarks
echo "::endgroup::"
- name: Fail early
Expand All @@ -718,6 +706,10 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: ./.github/actions/disk-cleanup

- name: Install toolchain
run: rustup show

Expand All @@ -731,13 +723,13 @@ jobs:
- name: Run runtime tests
run: |
echo "::group::rococo runtime test"
cargo test --locked --release -p rococo-parachain-runtime --lib
cargo test --locked -p rococo-parachain-runtime --lib
echo "::endgroup::"
echo "::group::litmus runtime test"
cargo test --locked --release -p litmus-parachain-runtime --lib
cargo test --locked -p litmus-parachain-runtime --lib
echo "::endgroup::"
echo "::group::litentry runtime test"
cargo test --locked --release -p litentry-parachain-runtime --lib
cargo test --locked -p litentry-parachain-runtime --lib
echo "::endgroup::"
- name: Fail early
Expand Down
24 changes: 6 additions & 18 deletions .github/workflows/create-release-draft.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,20 +119,16 @@ jobs:
if: ${{ github.event.inputs.parachain_client == 'true' }}
runs-on: ubuntu-latest
steps:
- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false

- name: Checkout codes on ${{ env.RELEASE_TAG }}
uses: actions/checkout@v4
with:
ref: ${{ env.RELEASE_TAG }}
fetch-depth: 0

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: ./.github/actions/disk-cleanup

- name: Build docker image
run: |
./scripts/build-docker.sh production ${{ env.RELEASE_TAG }}
Expand Down Expand Up @@ -179,11 +175,7 @@ jobs:

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false
uses: ./.github/actions/disk-cleanup

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
Expand Down Expand Up @@ -253,11 +245,7 @@ jobs:

- name: Free up disk space
if: startsWith(runner.name, 'GitHub Actions')
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
swap-storage: false
large-packages: false
uses: ./.github/actions/disk-cleanup

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
Expand Down
Loading

0 comments on commit b66d347

Please sign in to comment.