Skip to content

Commit

Permalink
Upgrade to polkadot-v0.9.16 (#596)
Browse files Browse the repository at this point in the history
* [CU-200y9ka] Auction: generate a file with weights (#470)

* CU-200y9ka - Auction: generate a file with weights

* Make clippy happier

* Fix tests

* Add remark check in CI (#220)

* Add remark check in CI

* Add a config file for remark

* Update config of CI

* Make remark happier

* Revert crowdloan bench (#485)

* refactor crowdloan benchmarking

* revert benchmarking integration of crowdloan rewards

* CU-1uq4a7x - ValidateUnsigned instead of SignedExtension in Crowdloan (#486)

* move crowdloan from SignedExtension to ValidateUnsigned

* revert transaction version upgrade as we removed the SignedExtra

* Check including wasm build (#489)

* Check including wasm build

* Add std feature check

* remove actions-rs from test step (#490)

* CU-1ubvcrq - introduce `Validated` and `Validate` for custom codec validation (#492)

* introduce `Validated` and `Validate` for custom codec validation

* add missing Deref/AsRef, use WrapperTypeEncode and introduce `And`

* devnet (#427)

* devnet release

* Build everything

* Use self hosted runners

* use pre-installed cargo

Co-authored-by: Karel L. Kubat <k.l.kubat@gmail.com>

* Fix devnet deployment (#502)

* fix

* only on main

* CU-1wty9p0 oracle api clarification (#462)

* oracle api clarification

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixing pr comments

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed comment

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* crazy fmt issue

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* just something to tirgget build after fail

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed price, added ratio test

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed comments

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* docs(Updated local devnet run information.): (#505)

Removed "--features develop" flag from local build command instructions.

Signed-off-by: Dominik Roth <dominik@composable.finance>

* CU-1yykjpw Fix calc_utilization_ratio() and add proptest for it.

* CU-1u5ykup - add generated types and refactor, add eth sign to crowdloan tests, bonded finance tests implementation (#487)

* add generated types and refactor tests, add eth sign to crowdloan

* Pulling bondPrice for bondedFinance Tests from variable

* test(bondedFinance TX Tests, Added mocha config file, Cleanup.):

(txBondedFinanceTests.ts): bondedFinance Extrinsic test
implementation.
(BondedFinance Pallet): MinReward now exposed through a
constant query.
(queryCrowdloanRewardsTests.ts): Updated checks and
timeout.

Following files have been removed, due to problems with the
new type implementation.
(queryTokenTests.ts): Removed Query Token Tests
(Partial stub and stopped working)
(querySystemAccountTests.ts): Removed
Query System Account Tests (Stopped working)

Added .mocharc.json configuration file.
Cleanup

Signed-off-by: Dominik Roth <dominik@composable.finance>

* test(bondedFinance TX Tests, bondedFinance pallet, Runtime Tests ReadMe):

(txBondedFinanceTests.ts): Moved test handlers into a folder to reduce
the file length. Also added additional tests.

(BondedFinance Pallet):
In cancel function, set keep-alive of second Transfer function to false.
Since clears the wallet of the staking account, and wasn't working
therefore.

(README.md): Changed timeout example to not show an infinite
timeout. Added run information for the type generator.

Signed-off-by: Dominik Roth <dominik@composable.finance>

Co-authored-by: Dominik Roth <96540347+Dom-Roth@users.noreply.github.com>
Co-authored-by: Dominik Roth <dominik@composable.finance>

* Add Makefile.toml (#506)

* Adds Benchmarking & Simnode (#497)

* check_runtime workflow

* check_runtime workflow

* Updates weights for picasso-dev

* update benchmark script

* update benchmark script

* support -> frame_support

* Updates weights for picasso-dev

* Updates weights for dali-dev

* fix conflict

* Add cargo.lock

* fix runtime.sh

* replace boldprint with echo

* adds set_changes_trie_config  to weights

* adds set_changes_trie_config  to weights

* Updates weights for picasso-dev

* hotpatch substrate

* fmt & clippy

* Updates weights for picasso-dev

* Update simnode script

* Update github workflow

* Update github workflow

* Updates weights for dali-dev

* Update github workflow

* Update github workflow

* Updates weights for composable-dev

* Add condition to ignore check_runtime on draft PR

* fmt

* adds +nighly to checks

* add git pull

* Finalizing cleanup

* Finalizing cleanup

* fmt fixes

* clippy fixes

* use +nightly-2021-11-29 for fmt

* Updates weights for picasso-dev

Co-authored-by: Seun Lanlege <seunlanlege@gmail.com>
Co-authored-by: haroldsphinx <haroldsphinx@gmail.com>

* CU-1wty1zv fixed lending (#484)

* oracle api clarification

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixing pr comments

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed comment

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* crazy fmt issue

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* just something to tirgget build after fail

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed lending

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed price, added ratio test

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed comments of review

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixed comments

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* Update benchmark workflow (#510)

* Update Makefile

* Update release

* Update

* Updating release

* Added runtime check

* Consolidate all branches into main

* Update check_runtime

* update benchmark workflow

* fix makefile

* diff base branch

* diff base branch

* diff base branch

* fix makefile

* github.ref

* i give up

* show-current

* use commit sha

* fetch main branch

* try again

Co-authored-by: Seun Lanlege <seunlanlege@gmail.com>

* Add <Bytes> tag for polkadotjs signature in crowdloan (#514)

The public polkadotjs api signRaw is wrapping the message in this tag.

* [CU-2326a8t] Update benchmarks of pallet-dutch-auction (#512)

* Update benchmarks of pallet-dutch-auction

* Update benchmarks of pallet-dutch-auction

* fix asset count to change an existing asset (#481)

* fix asset count to change an existing asset

* remove unused slash amount

* remove lingering slash amount

* handle better then default

* remove unwrap or defaults from asset_info

* fix benchmarks

* Add cleanup step (#515)


* Rollout Cleanup to fix max buffer error

* fix check runtime for main & releases (#513)

* fix check runtime for main & releases

* fix diffs

* conditionl artifact build

* fix syntax

* fix syntax

* testing

* take 2

* take 3

* seun 1 - 0 CI

* needs-benchmarks

* Update .maintain/client_release.sh

* fix release notes

* Add bump version (#519)

* fix workflow syntax

* Add cleanup step

* add bump version

* bump version and changelog

* bump version and changelog

* bump version and changelog

* bump version and changelog

* Release drafter update (#525)

* cleanup some CI cruft (#511)

* Cleanup CI and add rust-toolchain.toml

* remove .yarn

* fmt

* adds script to update draft release (#528)

* added oracle setup script (#503)

* Add BoundedSortedVec and SortedVec (#532)

* Add BoundedSortedVec and SortedVec

* fail on unsorted decodes

* adds paritytech/ci-linux:production (#536)

* added paritytech

* update branch trigger

* update run machines

* Update .github/workflows/paritytech.yml

* Apply suggestions from code review

* update cargo nightly

* update cargo exec path

* Update .github/workflows/check.yml

Co-authored-by: Seun Lanlege <seun@composable.finance>

* update check.yml

* use llvm-cov action

* prevent rust-toolchain.toml from overriding parity:ci

* update workflow file

* fix hadolint

* update hadolint to action

* remove image for unit test

* fix syntax error

* install cargo-llvm manually

* use image

* skip hadolint and remark

* add llvm-tools-preview

* run llvm-cov on runner

* update workflow file

* update workflow file

* force install

* llvm-cov in paritytech/ci-linux:production

* rustup show

* install llvm

* remove sudo

* one-line install

* apt-get install wget

* apt-get install wget

* apt-get install wget

* gnupg2

* run code-cov on runner

* path to cargo bin

* remove llvm installation

* use specific nightly version

* please just work

* sigh

Co-authored-by: Seun Lanlege <seun@composable.finance>
Co-authored-by: Seun Lanlege <seunlanlege@gmail.com>
Co-authored-by: haroldsphinx <adedayoakinpelu@gmail.com>

* substitute dali & picasso wasm in chainspec with tested wasm (#539)

* clean up release pipeline (#541)

* Add Acala's tests (#534)

* [CU-23t6rux] Add decimals for foreign assets in assets-registry (#552)

* Add decimals for foreign assets in assets-registry

* Renaming

* fixes #535 (#553)

* fixes #535

* don't skip integration tests

* remove ref: main

* get github ref from action

* try base_ref

* try GITHUB_SHA

* GITHUB_REF_NAME

* back to GITHUB_SHA

* checkout pull request commit

* renamee to release-pipeline

* back to

Co-authored-by: Seun Lanlege <seunlanlege@gmail.com>

* install stable+nightly (#554)

* Fix issue with git diff (#557)

* Fix issue with git diff

* rename git tags

* rename git tags

* deploy devnet from main (#559)

* kill stale jobs when pushing new changes (#562)

* kill stale jobs when pushing new changes

* test cancel

* test: Fixed docstrings and variable naming. (#529)

Signed-off-by: Dominik Roth <dominik@composable.finance>

test: Checks added to oracle tx tests, fixed crowdloan tx test.

Result checks added to oracle tx tests.
Fixed associate() tests for
crowdloan rewards.
Added oracle tx tests documentation.
Fixed Lint
configuration

Signed-off-by: Dominik Roth <dominik@composable.finance>

test: Fix test.ts calls.

Signed-off-by: Dominik Roth <dominik@composable.finance>

test(Oracle Runtime Tests): All oracle success tests implemented.

Signed-off-by: Dominik Roth <dominik@composable.finance>

fix(Runtime Tests Interfaces): Fixed faulty interface generation, due to changes to dutchAuction pallet.

Signed-off-by: Dominik Roth <dominik@composable.finance>

test(Better error messages.):

Signed-off-by: Dominik Roth <dominik@composable.finance>

test(bugfix):Tests erroring if result has no event attribute.
Updated polkadot api.

Signed-off-by: Dominik Roth <dominik@composable.finance>

test: Oracle Runtime Test Integration, Bugfix in Request function.

(txOracleTests.ts): Added addStake Test, fixed a few
issues.
(polkadotjs.ts): Fixed filter for missing event tag in request
result.
(.mocharc.json): Set retries per test to 0. This had caused
problems, due to multiple Promise returns, if the answer was just
delayed.
(tsconfig.json): Configured to resolve json modules.

Signed-off-by: Dominik Roth <dominik@composable.finance>

test: Oracle Tests Implementation, Configs & Deps, Cleanup

(txOracleTests.ts): Implemented first oracle
tests.

(txCrowdloanRewardsTests.ts): Cleanup.
(polkadotjs.ts): Switched
from lambda functions to normal ones.
(test.ts): Added oracle tests
calls and cleanup.
(mocharc.json): Added reporter configurations and
added .ts files to "watch-files".

Dependency update.

Signed-off-by: Dominik Roth <dominik@composable.finance>

test: Oracle Tests Implementation, Configs & Deps, Cleanup

(txOracleTests.ts): Implemented first oracle
tests.

(txCrowdloanRewardsTests.ts): Cleanup.
(polkadotjs.ts): Switched
from lambda functions to normal ones.
(test.ts): Added oracle tests
calls and cleanup.
(mocharc.json): Added reporter configurations and
added .ts files to "watch-files".
Fixed Mochawesome not exporting results.

Dependency update.

Signed-off-by: Dominik Roth <dominik@composable.finance>

* pallet mosaic (#547)

* initial commit

* save

* add a couple of tests

* add events everywhere

* Fix updating of penalty

* Add test for linear_decay

* remove unused variables

* add rescind_timelocked_mit and set_timelock_duration

* add tests for transfer_to and accept_transfer

* more tests and a fix

* enable todo in do_transfer_to

* avoid burning the full balance

* introduce tuple in scope instead of indexing

* fixup

* Split account into sub_accounts

* Fix do_transfer_to test by checking if the correct Event was emitted

* Fix timelocked_mint tests

* Fix issue where any user could remove IncomingTransactions belonging to any other account

* More mosaic docs

* introduce `TransactionType` and `SubAccount` to split incoming/ougoing accounts

Users were having their incoming/outgoing funds merged together into a single
sub_account within the pallet. Which would allow a bug to impact all the funds.
By splitting them, they are isolated.

* use tuple deconstruction instead of indexing

* format tests

* use `AssetId` instead of `CurrencyId` for consistency in tests

* implements more tests & fix some types used by mocking (accountId too small)

* Group transfer_to tests

* Add more test todos

* set_relayer tests

* rotate_relayer tests

* set_network tests

* more budget tests

* more mosaic tests

* mosaic timelocked_mint tests

* more mosaic timelocked_mint tests

* add a couple of tests

* Fix updating of penalty

* add tests for transfer_to and accept_transfer

* more tests and a fix

* Split account into sub_accounts

* Fix timelocked_mint tests

* More mosaic docs

* introduce `TransactionType` and `SubAccount` to split incoming/ougoing accounts

Users were having their incoming/outgoing funds merged together into a single
sub_account within the pallet. Which would allow a bug to impact all the funds.
By splitting them, they are isolated.

* format tests

* use `AssetId` instead of `CurrencyId` for consistency in tests

* implements more tests & fix some types used by mocking (accountId too small)

* Group transfer_to tests

* Add more test todos

* more mosaic tests

* mosaic timelocked_mint tests

* mosaic test claim_to

* convert first mosaic test to proptest

* proptest with unique AccountIds

* add prop_assert_err and prop_assert_noop

* use prop_assert_err and prop_assert_noop in mosaic tests

* rename decay types

* test decay of budget penalties for mints

* cargo fmt

* cargo fmt nightly

* forbid impossible state by avoiding default instance for RelayerConfig

We were using Default + ValueQuery for RelayerConfig.
It was fine because RelayerConfig was containing an `Option<AccountId>`
but this would allow inconsistent states such as None for RelayerConfig.current
& None for RelayerConfig.next.
By removing the option within RelayerConfig and using an OptionQuery for the
storage,
we it's more clear that a Relayer can be Set/Unset. And if set, an AcccountId
must be present.

* better naming

* fmt

* update test-helpers edition

* remove rust-version from mosaic

* refactor for consistency

* remove unused newline

* better naming

* more comments on decayer

* reflect the partial/complete nature of a transfer via the event

* rebase on main

* fiix difffd

* bump spec version for simnode

* fmt

Co-authored-by: kaiserkarel <k.l.kubat@gmail.com>
Co-authored-by: Hussein Ait Lahcen <hussein.aitlahcen@gmail.com>
Co-authored-by: Seun Lanlege <seunlanlege@gmail.com>

* CU-1ux3e25 CU-1q4x2t6 CU-1pdtjrz finalizing lending features (#546)

* make benchmark to work with labels (#563)

* make benchmark to work with labels

* trigger workflow based on label

* Update CODEOWNERS (#565)

* Bring mosaic in dali (#564)

* add missing constant/getter

* fix mosaic bringing std via num-traits default features

* add mosaic to dali runtime

* Bump node-fetch from 2.6.6 to 2.6.7 in /integration-tests/runtime-tests (#558)

Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.6 to 2.6.7.
- [Release notes](https://github.com/node-fetch/node-fetch/releases)
- [Commits](node-fetch/node-fetch@v2.6.6...v2.6.7)

---
updated-dependencies:
- dependency-name: node-fetch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

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

* update release drafter template (#566)

* Update sequence diagram of assets-registry (#568)

* fix for dalishot backup (#569)

* fix for dalishot backup

* testing backup

* testing backup

* testing backup

* testing backup

* cleanup

* exclude subxt

Co-authored-by: Seun Lanlege <seunlanlege@gmail.com>

* added label trigger (#576)

* added label trigger

* add if condition based on lable

* Simnode trigger (#577)

* added label trigger

* add if condition based on lable

* fix if statement

* Introduce ControlOrigin (#574)

* Introduce ControlOrigin

* import EnsureRoot

* CU-24fwjma Add implementation of codec::MaxEncodedLen in pallet-assets-registry (#575)

* Add implementation of codec::MaxEncodedLen for all types persisted to storage in assets-registry

* Bump spec_version

* Added 'std' features to Balances (#548)

* Added 'std' features to Balances

* Removed Balances from build dep

* some clippy and warnings and more checks (#570)

* some clippy and warnings and more checks

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixing build

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fix version again

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* tuning deny

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

* fixing rebase

Signed-off-by: Dzmitry Lahoda <dzmitry@lahoda.pro>

Co-authored-by: Ewere Diagboya <nimboya@gmail.com>

* CU-1nh9erq Implement basic DEX Router pallet. (#446)

* Implement basic DEX Router pallet.

* [CU-244gudh] Update dex-router (#561)

* Use BoundedVec instead of Vec in pallet-dex-router

* Add tests in pallet-dex-router

* Add TODO comment for minimum expected value as input parameter to `exchange()`.

Co-authored-by: andor0 <aaorlov1@gmail.com>

* CU-24fwjma Add MaxEncodedLen implementations in pallets (#580)

* Add MaxEncodedLen implementations in pallets

* Formatting

* all scripts: fail on error (#583)

* Inverted Validate trait (#572)

* failed to decode wrapped types

* inverted validate

* inverted existing impl of Validate

* Added module doc and examples

* cargo +nightly fmt

* fixed module doc examples

* removed commented out code

* restored validation

* cargo +nightly fmt

* made validate param more generic

* cleaned up validate calls

* add workflow for label validation (#582)

* simplify benchmarking (#585)

* disable logs during benchmarking

* Use wildcard for pallet selector

* re-add log filter

* tinker around more

* disable runtime change check

* add workflow dispatch trigger

* properly disable check for runtime changes

* Update simnode script (#590)

* Update simnode script

* Update simnode script

* Update simnode path (#592)

* Update simnode script

* Update simonde script

* Update simnode path (#593)

* Update simnode script

* Update simonde script

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* Pushing benchmark changes

* github action to upload benchmark commit

* github action to upload benchmark commit

Co-authored-by: haroldsphinx <haroldsphinx@users.noreply.github.com>

* Update simnode path (#594)

* Update simnode script

* Update simonde script

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

* Pushing benchmark changes

* github action to upload benchmark commit

* github action to upload benchmark commit

* github action to upload benchmark commit

Co-authored-by: haroldsphinx <haroldsphinx@users.noreply.github.com>

* Upgrade to polkadot-v0.9.16 (#567)

* switch deps

* add fork patch

* upgrade to v0.9.16

* wip parachain utils

* upgrade pallet-privilege to 0.9.16

* Add support of polkadot-v0.9.16 in pallet-oracle (#587)

* postpone upgrade

* missing maxencodedlen for defi struct

* style

* normalize orml-tokens/orml-traits and upgrade dex-router

* update cargolock

* derive MaxEncodedLen for Currency

* reorder

* revert registre MaxEncodedLen as XcmLocation does not implements it yet

* upgrade xcm related orml packages and add preimage

* format

* WIP: upgrade runtime, please CHECK THIS

* update cargo.lock

* upgrade node/chain_spec

* parachain_utils: make upgrade_runtime generic

* bump transaction version

* fmt

* parachain_utils:: minor fix

* parachain_utils: minor fixes

* Use BoundedVec instead of Vec (#589)

* upgrade executive, from AllPallets to AllPalletsReversedWithSystemFirst to
preserve previous behavior

* upgrade pallet mocks, adding missing MaxConsumers in sys config

* remove unused benchmark from composable

* fix oracle benchmarking

* update cargo.lock

* fix parachain-utils

* some stuff

* format

* fix tests/benchmarking

* update cargo.lock

* style

* some stuff

* upgrade xcm-emulator

* update cargo.lock

* ignore integration tests

* ignore simnode

* fix simnode

* benchmarks

* adds scheduler migrations

* cargo fmt

* bump runtime version

* cargo fmt

* fix benchmark workflow

* fix check benchmarks

* cargo fmt

* fix benchmark.yml

* fix runtime benchmark

* simnode stuff

* only benchmark picasso

* Pushing benchmark changes

* finalize picasso benchmarks

* fix weights

* cargo fmt

Co-authored-by: Hussein Ait Lahcen <hussein.aitlahcen@gmail.com>
Co-authored-by: david <wizdave97@gmail.com>
Co-authored-by: andor0 <aaorlov1@gmail.com>
Co-authored-by: seunlanlege <seunlanlege@users.noreply.github.com>

Co-authored-by: andor0 <aaorlov1@gmail.com>
Co-authored-by: Hussein Ait-Lahcen <hussein.aitlahcen@gmail.com>
Co-authored-by: Karel L. Kubat <k.l.kubat@gmail.com>
Co-authored-by: Dzmitry Lahoda <dzmitry@lahoda.pro>
Co-authored-by: Dominik Roth <96540347+Dom-Roth@users.noreply.github.com>
Co-authored-by: Vivek Pandya <vivekvpandya@gmail.com>
Co-authored-by: Dominik Roth <dominik@composable.finance>
Co-authored-by: Adedayo Akinpelu <adedayoakinpelu@gmail.com>
Co-authored-by: haroldsphinx <haroldsphinx@gmail.com>
Co-authored-by: JesseAbram <33698952+JesseAbram@users.noreply.github.com>
Co-authored-by: Ewere Diagboya <nimboya@gmail.com>
Co-authored-by: cor <cor@pruijs.dev>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Connor Davis <17688291+PoisonPhang@users.noreply.github.com>
Co-authored-by: haroldsphinx <haroldsphinx@users.noreply.github.com>
Co-authored-by: david <wizdave97@gmail.com>
Co-authored-by: seunlanlege <seunlanlege@users.noreply.github.com>
  • Loading branch information
18 people authored Feb 6, 2022
1 parent 4ea6181 commit 6b6a966
Show file tree
Hide file tree
Showing 298 changed files with 47,394 additions and 37,001 deletions.
2 changes: 1 addition & 1 deletion .config/cargo_spellcheck.dic
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ tombstoned
u128
Wasm
Xcm
XCM
Dispatchable
File renamed without changes.
5 changes: 4 additions & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,7 @@

# .github/ @haroldsphinx @seunlanlege
docker/ @haroldsphinx @seunlanlege
Makefile @haroldsphinx
runtime/ @seunlanlege
node/ @seunlanlege

Makefile @haroldsphinx
5 changes: 2 additions & 3 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
name-template: v$NEXT_PATCH_VERSION 🌈
tag-template: v$NEXT_PATCH_VERSION
commitish: releases
name-template: v$RESOLVED_VERSION 🌈
tag-template: v$RESOLVED_VERSION
categories:
- title: '🚀 Features'
labels:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/ansible-runner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ jobs:
- ansible-runner

steps:
- name: Clean up
continue-on-error: true
run: |
sudo chown -R $USER:$USER $GITHUB_WORKSPACE
docker system prune --force --all --volumes
- uses: actions/checkout@v2
with:
fetch-depth: 0
Expand Down
30 changes: 26 additions & 4 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,24 @@ name: Run Benchmarks

on:
pull_request:
types:
- labeled
branches:
- releases
- main
workflow_dispatch:

jobs:
benchmark:
benchmark:
name: Benchmark
runs-on:
- self-hosted
- linux
- x64
- bmark
concurrency:
group: bench-${{ github.ref }}
cancel-in-progress: true
if: github.event.pull_request.draft == false
steps:
- name: Clean up
Expand All @@ -24,18 +30,34 @@ jobs:
- uses: actions/checkout@v2
with:
ref: main
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}

- name: Get branch name
id: branch-name
uses: tj-actions/branch-names@v5.1

- name: Check for runtime changes
env:
BASE_BRANCH: ${{ github.event.pull_request.base.ref }}
GITHUB_BRANCH_NAME: ${{ steps.branch-name.outputs.current_branch }}

id: check_runtime
if: github.event.label.name == 'needs-benchmarks'
if: contains( github.event.pull_request.labels.*.name, 'needs-benchmarks')
run: .maintain/check_runtime.sh

- name: Benchmark Test
env:
BASE_BRANCH: ${{ github.event.pull_request.base.ref }}
GITHUB_BRANCH_NAME: ${{ steps.branch-name.outputs.current_branch }}

if: env.RUNTIME_CHECK == 1
id: run_benchmarks
run: .maintain/run_benchmarks.sh

- uses: EndBug/add-and-commit@v8
with:
add: 'runtime'
message: 'Pushing benchmark changes'
push: "true"
new_branch: ${{ steps.branch-name.outputs.current_branch }}
31 changes: 27 additions & 4 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ on:
- main
- develop
- releases

workflow_dispatch:

env:
DOCKER_USER_OPTION: '$UID:$GID'
Expand All @@ -20,6 +22,9 @@ jobs:
- linux
- x64
- sre
concurrency:
group: check-${{ github.ref }}
cancel-in-progress: true
container:
image: paritytech/ci-linux:production
steps:
Expand All @@ -44,6 +49,9 @@ jobs:
- linux
- x64
- sre
concurrency:
group: testcov-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Clean up
continue-on-error: true
Expand All @@ -61,7 +69,7 @@ jobs:
# TODO: https://github.com/ComposableFi/composable/issues/535
/home/runner/.cargo/bin/cargo install -f cargo-llvm-cov
/home/runner/.cargo/bin/rustup component add llvm-tools-preview --toolchain=nightly-2021-11-08
SKIP_WASM_BUILD=1 /home/runner/.cargo/bin/cargo +nightly-2021-11-08 llvm-cov --workspace --locked --release --verbose --features=runtime-benchmarks --exclude=integration-tests --lcov --output-path lcov.info
SKIP_WASM_BUILD=1 /home/runner/.cargo/bin/cargo +nightly-2021-11-08 llvm-cov --workspace --locked --release --verbose --features=runtime-benchmarks --lcov --output-path lcov.info
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
Expand All @@ -76,6 +84,9 @@ jobs:
- linux
- x64
- sre
concurrency:
group: tests-${{ github.ref }}
cancel-in-progress: true
container:
image: paritytech/ci-linux:production
steps:
Expand All @@ -91,7 +102,7 @@ jobs:
- uses: actions/checkout@v2
- name: Run Test
run: |
SKIP_WASM_BUILD=1 cargo test --workspace --locked --release --verbose --features=runtime-benchmarks --exclude=integration-tests
SKIP_WASM_BUILD=1 cargo test --workspace --locked --release --verbose --features=runtime-benchmarks
linters:
name: Linters
Expand All @@ -100,6 +111,9 @@ jobs:
- linux
- x64
- sre
concurrency:
group: lint-${{ github.ref }}
cancel-in-progress: true
container:
image: paritytech/ci-linux:production
steps:
Expand All @@ -111,6 +125,7 @@ jobs:
uses: actions/setup-node@v2
with:
node-version: 14.x

- name: Cargo fmt
run: |
cargo +nightly fmt --all -- --check
Expand Down Expand Up @@ -146,9 +161,18 @@ jobs:
./node_modules/.bin/remark -f $file || total_exit_code=$?
done << (find . -name "*.md" -not -path "*/node_modules/*" -not -path "./.github/*")
exit $total_exit_code
- name: Cargo clippy
run: |
SKIP_WASM_BUILD=1 env -u RUSTFLAGS cargo +nightly clippy --all-targets
SKIP_WASM_BUILD=1 env -u RUSTFLAGS cargo +nightly clippy --all-targets
- name: Cargo Single Depedency
# description: Speed up builds and reduced security check surface
run: |
cargo install -f cargo-deny
# start from minimal dependency crate
cargo deny --manifest-path ./frame/composable-support/Cargo.toml check Ban
- name: Cargo udeps
env:
UDEPS_VERSION: v0.1.24
Expand All @@ -160,4 +184,3 @@ jobs:
cargo udeps --version
SKIP_WASM_BUILD=1 cargo udeps --workspace --all-features
continue-on-error: true # Often this turns gives false positives, due to the different ways that Substrate uses features.

23 changes: 13 additions & 10 deletions .github/workflows/devnet-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,11 @@ on:

jobs:
deploy-devnet:
runs-on:
- ubuntu-latest
runs-on: ubuntu-latest
concurrency:
group: deploy-devnet
cancel-in-progress: false
steps:
- name: Clean up
continue-on-error: true
run: |
sudo chown -R $USER:$USER $GITHUB_WORKSPACE
docker system prune --force --all --volumes
- uses: actions/checkout@v2

- uses: google-github-actions/setup-gcloud@master
Expand All @@ -43,9 +35,20 @@ jobs:
run: |
echo "RELEASE_VERSION=$GITHUB_SHA" >> $GITHUB_ENV
- name: Install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable

- name: Install latest Nightly
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
target: wasm32-unknown-unknown

- name: Push artifact
run: |
/home/runner/.cargo/bin/cargo build --release
cargo build --release
tar -czvf composable-picasso-${{ env.RELEASE_VERSION }}.tar.gz target/release/composable
gsutil mv *.tar.gz gs://composable-binaries/community-releases/picasso/
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/docker-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,4 @@ jobs:

- name: Docker push
run: make push-release

20 changes: 20 additions & 0 deletions .github/workflows/label-validator.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: LabelValidator

on:
pull_request:
types: [opened, labeled, unlabeled, synchronize]
branches:
- releases

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Validate
uses: jesusvasquez333/verify-pr-label-action@v1.4.0
with:
github-token: ${{ secrets.REPO_TOKEN }}
valid-labels: 'major, minor, patch'
12 changes: 4 additions & 8 deletions .github/workflows/picashot.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: Picashot

name: Picasso and Dali Snapshot
on:
workflow_dispatch:
schedule:
Expand All @@ -20,18 +19,16 @@ jobs:
docker system prune --force --all --volumes
- name: Run ansible playbook
working-directory: ".maintain/playbooks"
run: |
pwd
ls
ansible-playbook -l _mainnet_collator_yes picashot.yml -i picasso-gcp.yaml --user root -e 'ansible_python_interpreter=/usr/bin/python3'
ansible-playbook -l _mainnet_collator_yes /opt/ansible/inventory/picashot.yml -i /opt/ansible/inventory/picasso-gcp.yaml --user root -e 'ansible_python_interpreter=/usr/bin/python3'
dalishot:
runs-on:
- self-hosted
- linux
- X64
- ansible-runner

steps:
- name: Clean up
continue-on-error: true
Expand All @@ -40,6 +37,5 @@ jobs:
docker system prune --force --all --volumes
- name: Run ansible playbook
working-directory: "./.maintain/playbooks"
run: |
ansible-playbook -l _collator_node_yes picashot.yml -i gcp.yaml --user runner -e 'ansible_python_interpreter=/usr/bin/python3'
ansible-playbook -l _collator_node_yes /opt/ansible/inventory/dalishot.yml -i /opt/ansible/inventory/gcp.yaml --user runner -e 'ansible_python_interpreter=/usr/bin/python3'
Loading

0 comments on commit 6b6a966

Please sign in to comment.