Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bifrost v0.9.82 #1026

Merged
merged 23 commits into from
Sep 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Release

env:
SUBWASM_VERSION: 0.19.0
SUBWASM_VERSION: 0.20.0

on:
push:
Expand Down Expand Up @@ -93,7 +93,7 @@ jobs:
${{ github.workspace }}/artifacts/bifrost_polkadot_runtime.compact.compressed.wasm

- uses: 8398a7/action-slack@v3
if: failure()
if: always()
with:
status: ${{ job.status }}
fields: repo,author,eventName,workflow,ref,commit
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/srtool.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Srtool build

env:
SUBWASM_VERSION: 0.19.0
SUBWASM_VERSION: 0.20.0

on:
workflow_dispatch:
Expand Down Expand Up @@ -31,7 +31,6 @@ jobs:
with:
chain: ${{ matrix.chain }}
runtime_dir: runtime/${{ matrix.chain }}
tag: 1.66.1
- name: Summary
run: |
echo '${{ steps.srtool_build.outputs.json }}' | jq > ${{ matrix.chain }}-srtool-digest.json
Expand Down
137 changes: 135 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ members = [
"pallets/parachain-staking",
"pallets/ve-minting",
"pallets/stable-pool",
"pallets/lend-market",
"pallets/prices",
"runtime/bifrost-kusama",
"runtime/bifrost-polkadot",
]
Expand Down Expand Up @@ -116,6 +118,7 @@ orml-xtokens = { git = "https://github.com/open-web3-stack/open-runtime-module-l
orml-unknown-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "4ae0372e2c624e6acc98305564b9d395f70814c0" }
orml-xcm = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "4ae0372e2c624e6acc98305564b9d395f70814c0" }
orml-xcm-support = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "4ae0372e2c624e6acc98305564b9d395f70814c0" }
orml-oracle = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "4ae0372e2c624e6acc98305564b9d395f70814c0" }
orml-utilities = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "4ae0372e2c624e6acc98305564b9d395f70814c0" }
xcm-emulator = { git = "https://github.com/shaunxw/xcm-simulator", rev = "d011e5ca62b93e8f688c2042c1f92cdbafc5d1d0" }

Expand Down
25 changes: 10 additions & 15 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,22 @@ build-bifrost-polkadot-release:
build-all-release: copy-genesis-config-release
cargo build -p node-cli --locked --features "with-all-runtime" --release

.PHONY: build-bifrost-rococo-fast-release # build bifrost rococo fast release
build-bifrost-rococo-fast-release:
cargo build -p node-cli --locked --features "with-bifrost-kusama-runtime,fast-runtime" --release


.PHONY: check-all # cargo check all runtime
check-all: format
SKIP_WASM_BUILD= cargo check -p node-cli --locked --features "with-all-runtime,runtime-benchmarks,try-runtime"

.PHONY: test-all # cargo test all runtime
test-all:
.PHONY: test-all # cargo test all
test-all: integration-test test-runtimes test-benchmarks


.PHONY: test-runtimes
test-runtimes:
SKIP_WASM_BUILD= cargo test --features "with-all-runtime" --lib

.PHONY: test-benchmarks
test-benchmarks:
cargo test --all benchmarking --features="runtime-benchmarks, polkadot" --exclude "*-integration-tests" --exclude "node-*" --exclude "*-runtime"

.PHONY: integration-test # integration test
integration-test:
SKIP_WASM_BUILD= cargo test -p *-integration-tests
Expand Down Expand Up @@ -67,10 +70,6 @@ format:
clippy:
cargo clippy --all --all-targets --features=with-all-runtime -- -D warnings

.PHONY: test-benchmarking # test with benchmarking
test-benchmarking:
cargo test --features runtime-benchmarks --features with-all-runtime --features --all benchmarking

.PHONY: benchmarking-staking # benchmarking staking pallet
benchmarking-staking:
cargo run -p node-cli --locked --features "with-bifrost-kusama-runtime,runtime-benchmarks" --release \
Expand Down Expand Up @@ -117,10 +116,6 @@ build-bifrost-polkadot-wasm:
build-bifrost-rococo-fast-wasm:
.maintain/build-wasm.sh bifrost-kusama fast

.PHONY: check-try-runtime # check try runtime
check-try-runtime:
SKIP_WASM_BUILD= cargo check --features try-runtime --features with-bifrost-runtime

.PHONY: try-kusama-runtime-upgrade # try kusama runtime upgrade
try-kusama-runtime-upgrade:
cargo run --features try-runtime --features with-bifrost-kusama-runtime --release \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,33 +67,28 @@ fn relaychain_transact_works() {
});

Bifrost::execute_with(|| {
// QueryStatus::Pending { responder: V3(MultiLocation { parents: 1, interior: Here }),
// maybe_match_querier: Some(V3(MultiLocation { parents: 0, interior: Here })),
// maybe_notify: Some((0, 7)), timeout: 100 } let query_id =
let notify_vote_call_weight = notify_vote_call.get_dispatch_info().weight;
let query_id = pallet_xcm::Pallet::<Runtime>::new_notify_query(
MultiLocation::parent(),
notify_vote_call,
100u32.into(),
Here,
);

// QueryResponse { query_id: 0, response: DispatchResult(Success), max_weight: Weight {
// ref_time: 4000000000, proof_size: 0 }, querier: Some(MultiLocation { parents: 0,
// interior: Here }) }
let asset: MultiAsset =
MultiAsset { id: Concrete(MultiLocation::here()), fun: Fungible(4000000000) };
MultiAsset { id: Concrete(MultiLocation::here()), fun: Fungible(517318631) };
let msg = Xcm(vec![
WithdrawAsset(asset.clone().into()),
BuyExecution { fees: asset, weight_limit: Unlimited },
Transact {
origin_kind: OriginKind::SovereignAccount,
require_weight_at_most: Weight::from_parts(4000000000, 100000),
require_weight_at_most: Weight::from_parts(961496000, 83866),
call: vote_call.encode().into(),
},
ReportTransactStatus(QueryResponseInfo {
destination: MultiLocation::from(X1(Parachain(2001))),
query_id,
max_weight: Weight::from_parts(3000000, 0),
max_weight: notify_vote_call_weight,
}),
RefundSurplus,
DepositAsset {
Expand Down
Loading