Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.

Commit a18a243

Browse files
committed
Merge branch 'master' into td-soft-deadline-conf
2 parents 19a9525 + e670c04 commit a18a243

File tree

621 files changed

+9152
-21611
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

621 files changed

+9152
-21611
lines changed

.github/workflows/polkadot-companion-labels.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
with:
1515
authToken: ${{ secrets.GITHUB_TOKEN }}
1616
ref: ${{ github.event.pull_request.head.sha }}
17-
contexts: 'continuous-integration/gitlab-check-polkadot-companion-build'
17+
contexts: 'continuous-integration/gitlab-check-dependent-polkadot'
1818
timeout: 1800
1919
notPresentTimeout: 3600 # It can take quite a while before the job starts on Gitlab when the CI queue is large
2020
failureStates: failure

.gitlab-ci.yml

Lines changed: 17 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ variables: &default-vars
4040
ARCH: "x86_64"
4141
CI_IMAGE: "paritytech/ci-linux:production"
4242
# FIXME set to release
43-
CARGO_UNLEASH_INSTALL_PARAMS: "--version 1.0.0-alpha.12"
44-
CARGO_UNLEASH_PKG_DEF: "--skip node node-* pallet-template pallet-example pallet-example-* subkey chain-spec-builder"
43+
CARGO_UNLEASH_INSTALL_PARAMS: "--version 1.0.0-alpha.13"
44+
CARGO_UNLEASH_PKG_DEF: "--skip node node-* pallet-template pallet-example-* subkey chain-spec-builder"
4545
VAULT_SERVER_URL: "https://vault.parity-mgmt-vault.parity.io"
4646
VAULT_AUTH_PATH: "gitlab-parity-io-jwt"
4747
VAULT_AUTH_ROLE: "cicd_gitlab_parity_${CI_PROJECT_NAME}"
@@ -455,20 +455,20 @@ test-linux-stable: &test-linux
455455
- SUBSTRATE_TEST_TIMEOUT=1 time cargo test -p substrate-test-utils --release --verbose --locked -- --ignored timeout
456456
- sccache -s
457457

458-
#unleash-check:
459-
#stage: test
460-
#<<: *docker-env
461-
#<<: *test-refs-no-trigger
462-
#script:
463-
#- cargo install cargo-unleash ${CARGO_UNLEASH_INSTALL_PARAMS}
464-
#- cargo unleash de-dev-deps
458+
unleash-check:
459+
stage: test
460+
<<: *docker-env
461+
<<: *test-refs-no-trigger
462+
script:
463+
- cargo install cargo-unleash ${CARGO_UNLEASH_INSTALL_PARAMS}
464+
- cargo unleash de-dev-deps
465465
# Reuse build artifacts when running checks (cuts down check time by 3x)
466466
# TODO: Implement this optimization in cargo-unleash rather than here
467-
#- mkdir -p target/unleash
468-
#- export CARGO_TARGET_DIR=target/unleash
469-
#- cargo unleash check ${CARGO_UNLEASH_PKG_DEF}
467+
- mkdir -p target/unleash
468+
- export CARGO_TARGET_DIR=target/unleash
469+
- cargo unleash check ${CARGO_UNLEASH_PKG_DEF}
470470
# FIXME: this job must not fail, or unleash-to-crates-io will publish broken stuff
471-
#allow_failure: true
471+
allow_failure: true
472472

473473
test-frame-examples-compile-to-wasm:
474474
# into one job
@@ -482,9 +482,9 @@ test-frame-examples-compile-to-wasm:
482482
RUSTFLAGS: "-Cdebug-assertions=y"
483483
RUST_BACKTRACE: 1
484484
script:
485-
- cd frame/example-offchain-worker/
485+
- cd frame/examples/offchain-worker/
486486
- cargo +nightly build --target=wasm32-unknown-unknown --no-default-features
487-
- cd ../example
487+
- cd ../basic
488488
- cargo +nightly build --target=wasm32-unknown-unknown --no-default-features
489489
- sccache -s
490490

@@ -661,8 +661,7 @@ build-rustdoc:
661661
- ./crate-docs/
662662
script:
663663
# FIXME: it fails with `RUSTDOCFLAGS="-Dwarnings"`
664-
- RUSTDOCFLAGS="--html-in-header $(pwd)/.maintain/rustdoc-header.html"
665-
time cargo +nightly doc --no-deps --workspace --all-features --verbose
664+
- time cargo +nightly doc --workspace --all-features --verbose
666665
- rm -f ./target/doc/.lock
667666
- mv ./target/doc ./crate-docs
668667
# FIXME: remove me after CI image gets nonroot
@@ -873,9 +872,7 @@ unleash-to-crates-io:
873872
<<: *vault-secrets
874873
rules:
875874
- if: $CI_COMMIT_REF_NAME =~ /^ci-release-.*$/
876-
# FIXME: wait until https://github.com/paritytech/cargo-unleash/issues/50 is fixed, also
877-
# remove allow_failure: true on the check job
878-
# - if: $CI_COMMIT_REF_NAME =~ /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1
875+
- if: $CI_COMMIT_REF_NAME =~ /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1
879876
script:
880877
- cargo install cargo-unleash ${CARGO_UNLEASH_INSTALL_PARAMS}
881878
- cargo unleash em-dragons --no-check --owner github:paritytech:core-devs ${CARGO_UNLEASH_PKG_DEF}

.maintain/frame-weight-template.hbs

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
//! EXECUTION: {{cmd.execution}}, WASM-EXECUTION: {{cmd.wasm_execution}}, CHAIN: {{cmd.chain}}, DB CACHE: {{cmd.db_cache}}
2323

2424
// Executed Command:
25-
{{#each args as |arg|~}}
25+
{{#each args as |arg|}}
2626
// {{arg}}
2727
{{/each}}
2828

@@ -35,80 +35,80 @@ use sp_std::marker::PhantomData;
3535

3636
/// Weight functions needed for {{pallet}}.
3737
pub trait WeightInfo {
38-
{{~#each benchmarks as |benchmark|}}
38+
{{#each benchmarks as |benchmark|}}
3939
fn {{benchmark.name~}}
4040
(
4141
{{~#each benchmark.components as |c| ~}}
4242
{{c.name}}: u32, {{/each~}}
4343
) -> Weight;
44-
{{~/each}}
44+
{{/each}}
4545
}
4646

4747
/// Weights for {{pallet}} using the Substrate node and recommended hardware.
4848
pub struct SubstrateWeight<T>(PhantomData<T>);
49-
{{~#if (eq pallet "frame_system")}}
49+
{{#if (eq pallet "frame_system")}}
5050
impl<T: crate::Config> WeightInfo for SubstrateWeight<T> {
51-
{{~else}}
51+
{{else}}
5252
impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
53-
{{~/if}}
54-
{{~#each benchmarks as |benchmark|}}
55-
{{~#each benchmark.comments as |comment|}}
53+
{{/if}}
54+
{{#each benchmarks as |benchmark|}}
55+
{{#each benchmark.comments as |comment|}}
5656
// {{comment}}
57-
{{~/each}}
57+
{{/each}}
5858
fn {{benchmark.name~}}
5959
(
6060
{{~#each benchmark.components as |c| ~}}
6161
{{~#if (not c.is_used)}}_{{/if}}{{c.name}}: u32, {{/each~}}
6262
) -> Weight {
6363
({{underscore benchmark.base_weight}} as Weight)
64-
{{~#each benchmark.component_weight as |cw|}}
64+
{{#each benchmark.component_weight as |cw|}}
6565
// Standard Error: {{underscore cw.error}}
6666
.saturating_add(({{underscore cw.slope}} as Weight).saturating_mul({{cw.name}} as Weight))
67-
{{~/each}}
68-
{{~#if (ne benchmark.base_reads "0")}}
67+
{{/each}}
68+
{{#if (ne benchmark.base_reads "0")}}
6969
.saturating_add(T::DbWeight::get().reads({{benchmark.base_reads}} as Weight))
70-
{{~/if}}
71-
{{~#each benchmark.component_reads as |cr|}}
70+
{{/if}}
71+
{{#each benchmark.component_reads as |cr|}}
7272
.saturating_add(T::DbWeight::get().reads(({{cr.slope}} as Weight).saturating_mul({{cr.name}} as Weight)))
73-
{{~/each}}
74-
{{~#if (ne benchmark.base_writes "0")}}
73+
{{/each}}
74+
{{#if (ne benchmark.base_writes "0")}}
7575
.saturating_add(T::DbWeight::get().writes({{benchmark.base_writes}} as Weight))
76-
{{~/if}}
77-
{{~#each benchmark.component_writes as |cw|}}
76+
{{/if}}
77+
{{#each benchmark.component_writes as |cw|}}
7878
.saturating_add(T::DbWeight::get().writes(({{cw.slope}} as Weight).saturating_mul({{cw.name}} as Weight)))
79-
{{~/each}}
79+
{{/each}}
8080
}
81-
{{~/each}}
81+
{{/each}}
8282
}
8383

8484
// For backwards compatibility and tests
8585
impl WeightInfo for () {
86-
{{~#each benchmarks as |benchmark|}}
87-
{{~#each benchmark.comments as |comment|}}
86+
{{#each benchmarks as |benchmark|}}
87+
{{#each benchmark.comments as |comment|}}
8888
// {{comment}}
89-
{{~/each}}
89+
{{/each}}
9090
fn {{benchmark.name~}}
9191
(
9292
{{~#each benchmark.components as |c| ~}}
9393
{{~#if (not c.is_used)}}_{{/if}}{{c.name}}: u32, {{/each~}}
9494
) -> Weight {
9595
({{underscore benchmark.base_weight}} as Weight)
96-
{{~#each benchmark.component_weight as |cw|}}
96+
{{#each benchmark.component_weight as |cw|}}
9797
// Standard Error: {{underscore cw.error}}
9898
.saturating_add(({{underscore cw.slope}} as Weight).saturating_mul({{cw.name}} as Weight))
99-
{{~/each}}
100-
{{~#if (ne benchmark.base_reads "0")}}
99+
{{/each}}
100+
{{#if (ne benchmark.base_reads "0")}}
101101
.saturating_add(RocksDbWeight::get().reads({{benchmark.base_reads}} as Weight))
102-
{{~/if}}
103-
{{~#each benchmark.component_reads as |cr|}}
102+
{{/if}}
103+
{{#each benchmark.component_reads as |cr|}}
104104
.saturating_add(RocksDbWeight::get().reads(({{cr.slope}} as Weight).saturating_mul({{cr.name}} as Weight)))
105-
{{~/each}}
106-
{{~#if (ne benchmark.base_writes "0")}}
105+
{{/each}}
106+
{{#if (ne benchmark.base_writes "0")}}
107107
.saturating_add(RocksDbWeight::get().writes({{benchmark.base_writes}} as Weight))
108-
{{~/if}}
109-
{{~#each benchmark.component_writes as |cw|}}
108+
{{/if}}
109+
{{#each benchmark.component_writes as |cw|}}
110110
.saturating_add(RocksDbWeight::get().writes(({{cw.slope}} as Weight).saturating_mul({{cw.name}} as Weight)))
111-
{{~/each}}
111+
{{/each}}
112112
}
113-
{{~/each}}
113+
{{/each}}
114114
}

.maintain/node-template-release/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "node-template-release"
33
version = "3.0.0"
44
authors = ["Parity Technologies <[email protected]>"]
5-
edition = "2018"
5+
edition = "2021"
66
license = "GPL-3.0"
77

88
[dependencies]

.maintain/rustdoc-header.html

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)