Skip to content

Commit 712ec4a

Browse files
author
talentdev219
committed
Fix to CI/CD build try-runtime error (#637)
1 parent 33c4b3b commit 712ec4a

File tree

1 file changed

+60
-57
lines changed

1 file changed

+60
-57
lines changed

.github/workflows/ci.yml

+60-57
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
env:
1010
nightly: nightly
1111
target: wasm32-unknown-unknown
12-
tarpaulin-vers: '0.20.0'
12+
tarpaulin-vers: "0.20.0"
1313
try-runtime-chain: dev
1414
try-runtime-uri: wss://nodle-parachain.api.onfinality.io:443/public-ws
1515

@@ -18,62 +18,63 @@ jobs:
1818
runs-on: ubuntu-latest
1919

2020
steps:
21-
- uses: actions/checkout@v2
22-
- uses: actions-rs/toolchain@v1
23-
with:
24-
profile: minimal
25-
toolchain: ${{ env.nightly }}
26-
override: true
27-
target: ${{ env.target }}
28-
components: rustfmt,clippy
29-
30-
- name: Cache cargo registry
31-
uses: actions/[email protected]
32-
with:
33-
path: ~/.cargo/registry
34-
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
35-
restore-keys: |
36-
${{ runner.os }}-cargo-registry-
37-
38-
- name: Cache cargo index
39-
uses: actions/[email protected]
40-
with:
41-
path: ~/.cargo/git
42-
key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }}
43-
restore-keys: |
44-
${{ runner.os }}-cargo-index-
45-
46-
- name: Cache cargo build
47-
uses: actions/[email protected]
48-
with:
49-
path: target
50-
key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }}
51-
restore-keys: |
52-
${{ runner.os }}-cargo-build-target-
53-
54-
- name: Fmt
55-
uses: actions-rs/cargo@v1
56-
with:
57-
toolchain: ${{ env.nightly }}
58-
command: fmt
59-
60-
- name: Clippy
61-
uses: actions-rs/clippy-check@v1
62-
with:
63-
token: ${{ secrets.GITHUB_TOKEN }}
64-
args: --all-features -- -A clippy::type_complexity -A clippy::identity_op -A clippy::boxed_local -D dead_code
65-
toolchain: ${{ env.nightly }}
66-
67-
- name: Run cargo-tarpaulin
68-
uses: actions-rs/[email protected]
69-
with:
70-
version: ${{ env.tarpaulin-vers }}
71-
args: '--avoid-cfg-tarpaulin --all-features --workspace --timeout 120 --exclude runtimes-eden runtimes-main runtimes-staking nodle-chain nodle-parachain nodle-staking --exclude-files **/mock.rs **/weights.rs **/weights/*'
72-
73-
- name: Upload to Codecov
74-
uses: codecov/[email protected]
75-
with:
76-
fail_ci_if_error: true
21+
- uses: actions/checkout@v2
22+
- uses: actions-rs/toolchain@v1
23+
with:
24+
profile: minimal
25+
toolchain: ${{ env.nightly }}
26+
override: true
27+
target: ${{ env.target }}
28+
components: rustfmt,clippy
29+
30+
- name: Cache cargo registry
31+
uses: actions/[email protected]
32+
with:
33+
path: ~/.cargo/registry
34+
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
35+
restore-keys: |
36+
${{ runner.os }}-cargo-registry-
37+
38+
- name: Cache cargo index
39+
uses: actions/[email protected]
40+
with:
41+
path: ~/.cargo/git
42+
key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }}
43+
restore-keys: |
44+
${{ runner.os }}-cargo-index-
45+
46+
- name: Cache cargo build
47+
uses: actions/[email protected]
48+
with:
49+
path: target
50+
key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }}
51+
restore-keys: |
52+
${{ runner.os }}-cargo-build-target-
53+
54+
- name: Fmt
55+
uses: actions-rs/cargo@v1
56+
with:
57+
toolchain: ${{ env.nightly }}
58+
command: fmt
59+
60+
- name: Clippy
61+
uses: actions-rs/clippy-check@v1
62+
with:
63+
token: ${{ secrets.GITHUB_TOKEN }}
64+
args: --all-features -- -A clippy::type_complexity -A clippy::identity_op -A clippy::boxed_local -D dead_code
65+
toolchain: ${{ env.nightly }}
66+
67+
- name: Run cargo-tarpaulin
68+
uses: actions-rs/[email protected]
69+
with:
70+
version: ${{ env.tarpaulin-vers }}
71+
args: "--avoid-cfg-tarpaulin --all-features --workspace --timeout 120 --exclude runtimes-eden runtimes-main runtimes-staking nodle-chain nodle-parachain nodle-staking --exclude-files **/mock.rs **/weights.rs **/weights/*"
72+
73+
- name: Upload to Codecov
74+
uses: codecov/[email protected]
75+
with:
76+
fail_ci_if_error: true
77+
7778

7879
try-runtime:
7980
runs-on: ubuntu-latest
@@ -85,13 +86,15 @@ jobs:
8586
with:
8687
profile: minimal
8788
toolchain: stable
89+
target: ${{ env.target }}
8890

8991
- name: Install Rust nightly
9092
uses: actions-rs/toolchain@v1
9193
with:
9294
profile: minimal
9395
toolchain: ${{ env.nightly }}
9496
target: ${{ env.target }}
97+
default: true
9598

9699
- name: Try Runtime
97100
uses: actions-rs/cargo@v1

0 commit comments

Comments
 (0)