diff --git a/Cargo.lock b/Cargo.lock index 6e80be1..7c62e66 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2703,6 +2703,8 @@ checksum = "a357d28ed41a50f9c765dbfe56cbc04a64e53e5fc58ba79fbc34c10ef3df831f" [[package]] name = "encointer-balances-tx-payment" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be09b48ab6e4cdf6316cd3faf036940c4517d149499f07c9e3ddfb70dcc71488" dependencies = [ "encointer-primitives", "frame-support", @@ -2715,9 +2717,36 @@ dependencies = [ "sp-runtime", ] +[[package]] +name = "encointer-balances-tx-payment-rpc" +version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8583b249b884e661790afe7a998562ce7028e83c6078013b23621dfa0c995bce" +dependencies = [ + "encointer-balances-tx-payment-rpc-runtime-api", + "encointer-primitives", + "encointer-rpc", + "jsonrpsee", + "log", + "pallet-transaction-payment", + "pallet-transaction-payment-rpc", + "parity-scale-codec", + "parking_lot 0.12.1", + "sc-rpc", + "sc-rpc-api", + "sp-api", + "sp-blockchain", + "sp-core", + "sp-rpc", + "sp-runtime", + "thiserror", +] + [[package]] name = "encointer-balances-tx-payment-rpc-runtime-api" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "817560882892e4527f08b152a300772057317725a335e15ce654a07adb60d9d8" dependencies = [ "encointer-primitives", "frame-support", @@ -2730,6 +2759,8 @@ dependencies = [ [[package]] name = "encointer-ceremonies-assignment" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06fb1e51610f1aedf130a9909977943e75de4d44218c60fc73f78b8b410ef872" dependencies = [ "encointer-primitives", "sp-runtime", @@ -2757,6 +2788,7 @@ dependencies = [ "cumulus-relay-chain-inprocess-interface", "cumulus-relay-chain-interface", "cumulus-relay-chain-rpc-interface", + "encointer-balances-tx-payment-rpc", "encointer-balances-tx-payment-rpc-runtime-api", "encointer-kusama-runtime", "frame-benchmarking", @@ -2823,6 +2855,7 @@ dependencies = [ [[package]] name = "encointer-kusama-runtime" version = "1.0.0" +source = "git+https://github.com/encointer/runtimes.git?branch=ab/introduce_collator-selection#264d867610f6b9c8bb86598862a30bf92d12d62a" dependencies = [ "cumulus-pallet-aura-ext", "cumulus-pallet-parachain-system", @@ -2900,6 +2933,8 @@ dependencies = [ [[package]] name = "encointer-meetup-validation" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f7840e8d6e88ac1f2393f6cf5003471663585f8c43d94b26c2e3d4376248148" dependencies = [ "encointer-primitives", "parity-scale-codec", @@ -2912,6 +2947,8 @@ dependencies = [ [[package]] name = "encointer-primitives" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf4b67ace89f88af02b70f36c8668222bcfc3ac0cac48ac92007ed1218a7643e" dependencies = [ "bs58 0.5.1", "crc", @@ -2931,6 +2968,8 @@ dependencies = [ [[package]] name = "encointer-rpc" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2dd4255adcf89012e75724cc404000c9008bfe4d59eae12691b153fd87191e0" dependencies = [ "jsonrpsee", "jsonrpsee-core", @@ -3003,6 +3042,8 @@ checksum = "e48c92028aaa870e83d51c64e5d4e0b6981b360c522198c23959f219a4e1b15b" [[package]] name = "ep-core" version = "6.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b20f3b698c54e106bcb0533055bf99d64ae9c53261e7ed24366d1ca729a1259" dependencies = [ "array-bytes 6.2.2", "impl-serde", @@ -6539,6 +6580,8 @@ dependencies = [ [[package]] name = "pallet-encointer-balances" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb968c2b87c3ef3ef67e5da9237b6c9b32218762b9e69bf523ddea4f55a5f260" dependencies = [ "approx", "encointer-primitives", @@ -6557,6 +6600,8 @@ dependencies = [ [[package]] name = "pallet-encointer-bazaar" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1a4f6a43dce9ec7470ce65716b7009e86eda70f18e3f7690a4841a05d471f10" dependencies = [ "encointer-primitives", "frame-benchmarking", @@ -6573,6 +6618,8 @@ dependencies = [ [[package]] name = "pallet-encointer-bazaar-rpc" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f6c04106fbea30496065f4fb6dab694d2ab302dbe2ac1fce102e71002843a90" dependencies = [ "encointer-primitives", "encointer-rpc", @@ -6592,6 +6639,8 @@ dependencies = [ [[package]] name = "pallet-encointer-bazaar-rpc-runtime-api" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "430c3a5bcaa9d2fd7ab314b8e50222c8645699b3157448eabed64b65ad4cf801" dependencies = [ "encointer-primitives", "frame-support", @@ -6603,6 +6652,8 @@ dependencies = [ [[package]] name = "pallet-encointer-ceremonies" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87c965513d515c8b74d1d526f999d58aad713462887e290c5295ae2ca13f4b97" dependencies = [ "encointer-ceremonies-assignment", "encointer-meetup-validation", @@ -6627,6 +6678,8 @@ dependencies = [ [[package]] name = "pallet-encointer-ceremonies-rpc" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf89bf4659e84301332b12fd11688f4e8798b804a83c5701dae78bcb65fb4b68" dependencies = [ "encointer-primitives", "encointer-rpc", @@ -6646,6 +6699,8 @@ dependencies = [ [[package]] name = "pallet-encointer-ceremonies-rpc-runtime-api" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "562c6c756d356318dead2e90710b1c7cee12a6e2ff9aa555e6782ba5202fcde0" dependencies = [ "encointer-primitives", "frame-support", @@ -6657,6 +6712,8 @@ dependencies = [ [[package]] name = "pallet-encointer-communities" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "efdbb9bac32cd764992ced4055e76c6d09907f5ac3863d1d19f14edda7eaa3ac" dependencies = [ "encointer-primitives", "frame-benchmarking", @@ -6675,6 +6732,8 @@ dependencies = [ [[package]] name = "pallet-encointer-communities-rpc" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53da1621388859e89f8b067dca9ca6dcf587755b81ca9c455e7cc3332a8d2f3d" dependencies = [ "encointer-primitives", "encointer-rpc", @@ -6695,6 +6754,8 @@ dependencies = [ [[package]] name = "pallet-encointer-communities-rpc-runtime-api" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c10de1b47024c9c7a957521eb29edcf7c9cf31d8c70eee7e991d11f43d137606" dependencies = [ "encointer-primitives", "parity-scale-codec", @@ -6705,6 +6766,8 @@ dependencies = [ [[package]] name = "pallet-encointer-faucet" version = "6.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3024bc49c1fd7fffa68f4aa636b199c7a0772690049d0471a6b60d17080024d8" dependencies = [ "approx", "encointer-primitives", @@ -6724,6 +6787,8 @@ dependencies = [ [[package]] name = "pallet-encointer-reputation-commitments" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9029fcdd0cd76e41d067bcf7f09860b4018de9c5382ab1b8006823e2fa148ac5" dependencies = [ "approx", "encointer-primitives", @@ -6745,6 +6810,8 @@ dependencies = [ [[package]] name = "pallet-encointer-scheduler" version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a13047a59df28111d0e6bd64ca45fa95fe1b97021ba244fe3f7fe3a2edbf2e2c" dependencies = [ "encointer-primitives", "frame-benchmarking", @@ -14944,11 +15011,3 @@ dependencies = [ "cc", "pkg-config", ] - -[[patch.unused]] -name = "kusama-runtime-constants" -version = "1.0.0" - -[[patch.unused]] -name = "encointer-balances-tx-payment-rpc" -version = "6.1.0" diff --git a/Cargo.toml b/Cargo.toml index 876a001..2c3664d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -42,10 +42,11 @@ pallet-encointer-scheduler = { default-features = false, version = "~6.1.0" } pallet-encointer-bazaar-rpc = "~6.1.0" pallet-encointer-ceremonies-rpc = "~6.1.0" pallet-encointer-communities-rpc = "~6.1.0" +encointer-balances-tx-payment-rpc = "~6.1.0" # fellowship runtimes. do not depend on fellow-runtimes directly, so we can upgrade at our own pace -kusama-runtime-constants = { default-features = false, git = "https://github.com/encointer/runtimes.git", branch = "ab/upgrade-encointer-to-6.1" } -parachain-runtime = { package = "encointer-kusama-runtime", git = "https://github.com/encointer/runtimes.git", branch = "ab/upgrade-encointer-to-6.1" } +kusama-runtime-constants = { default-features = false, git = "https://github.com/encointer/runtimes.git", branch = "ab/introduce_collator-selection" } +parachain-runtime = { package = "encointer-kusama-runtime", git = "https://github.com/encointer/runtimes.git", branch = "ab/introduce_collator-selection" } # polkadot-sdk [no_std] cumulus-pallet-aura-ext = { default-features = false, version = "0.8.0" } @@ -144,26 +145,26 @@ substrate-build-script-utils = "11.0.0" substrate-prometheus-endpoint = "0.17.0" # ### only while debugging/developping -[patch."https://github.com/encointer/runtimes"] -kusama-runtime-constants = { path = "../runtimes/relay/kusama/constants" } -parachain-runtime = { package = "encointer-kusama-runtime", path = "../runtimes/system-parachains/encointer" } - -[patch.crates-io] -encointer-balances-tx-payment = { path = "../pallets/balances-tx-payment" } -encointer-balances-tx-payment-rpc = { path = "../pallets/balances-tx-payment/rpc" } -encointer-balances-tx-payment-rpc-runtime-api = { path = "../pallets/balances-tx-payment/rpc/runtime-api" } -encointer-ceremonies-assignment = { path = "../pallets/ceremonies/assignment" } -encointer-primitives = { path = "../pallets/primitives" } -pallet-encointer-ceremonies = { path = "../pallets/ceremonies" } -pallet-encointer-ceremonies-rpc = { path = "../pallets/ceremonies/rpc" } -pallet-encointer-ceremonies-rpc-runtime-api = { path = "../pallets/ceremonies/rpc/runtime-api" } -pallet-encointer-communities = { path = "../pallets/communities" } -pallet-encointer-communities-rpc = { path = "../pallets/communities/rpc" } -pallet-encointer-communities-rpc-runtime-api = { path = "../pallets/communities/rpc/runtime-api" } -pallet-encointer-balances = { path = "../pallets/balances" } -pallet-encointer-scheduler = { path = "../pallets/scheduler" } -pallet-encointer-bazaar = { path = "../pallets/bazaar" } -pallet-encointer-bazaar-rpc = { path = "../pallets/bazaar/rpc" } -pallet-encointer-bazaar-rpc-runtime-api = { path = "../pallets/bazaar/rpc/runtime-api" } -pallet-encointer-faucet = { path = "../pallets/faucet" } -pallet-encointer-reputation-commitments = { path = "../pallets/reputation-commitments" } +#[patch."https://github.com/encointer/runtimes"] +#kusama-runtime-constants = { path = "../runtimes/relay/kusama/constants" } +#parachain-runtime = { package = "encointer-kusama-runtime", path = "../runtimes/system-parachains/encointer" } +# +#[patch.crates-io] +#encointer-balances-tx-payment = { path = "../pallets/balances-tx-payment" } +#encointer-balances-tx-payment-rpc = { path = "../pallets/balances-tx-payment/rpc" } +#encointer-balances-tx-payment-rpc-runtime-api = { path = "../pallets/balances-tx-payment/rpc/runtime-api" } +#encointer-ceremonies-assignment = { path = "../pallets/ceremonies/assignment" } +#encointer-primitives = { path = "../pallets/primitives" } +#pallet-encointer-ceremonies = { path = "../pallets/ceremonies" } +#pallet-encointer-ceremonies-rpc = { path = "../pallets/ceremonies/rpc" } +#pallet-encointer-ceremonies-rpc-runtime-api = { path = "../pallets/ceremonies/rpc/runtime-api" } +#pallet-encointer-communities = { path = "../pallets/communities" } +#pallet-encointer-communities-rpc = { path = "../pallets/communities/rpc" } +#pallet-encointer-communities-rpc-runtime-api = { path = "../pallets/communities/rpc/runtime-api" } +#pallet-encointer-balances = { path = "../pallets/balances" } +#pallet-encointer-scheduler = { path = "../pallets/scheduler" } +#pallet-encointer-bazaar = { path = "../pallets/bazaar" } +#pallet-encointer-bazaar-rpc = { path = "../pallets/bazaar/rpc" } +#pallet-encointer-bazaar-rpc-runtime-api = { path = "../pallets/bazaar/rpc/runtime-api" } +#pallet-encointer-faucet = { path = "../pallets/faucet" } +#pallet-encointer-reputation-commitments = { path = "../pallets/reputation-commitments" } diff --git a/node/Cargo.toml b/node/Cargo.toml index d88a6e6..2353526 100644 --- a/node/Cargo.toml +++ b/node/Cargo.toml @@ -29,6 +29,7 @@ serde_json = { workspace = true } parachain-runtime = { workspace = true, features = ["std"] } # encointer dependencies +encointer-balances-tx-payment-rpc = { workspace = true } encointer-balances-tx-payment-rpc-runtime-api = { workspace = true, features = ["std"] } pallet-encointer-bazaar-rpc = { workspace = true } pallet-encointer-bazaar-rpc-runtime-api = { workspace = true, features = ["std"] } diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index 8a708f2..f15a0b1 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -16,7 +16,7 @@ use cumulus_primitives_core::ParaId; use parachain_runtime::{BalanceType, CeremonyPhaseType}; -use parachains_common::{AccountId, AuraId, Balance}; +use parachains_common::{AccountId, Balance}; use parity_scale_codec::{Decode, Encode}; use sc_chain_spec::{ChainSpecExtension, ChainSpecGroup}; use serde::{Deserialize, Serialize}; diff --git a/node/src/rpc.rs b/node/src/rpc.rs index 91f5f98..28ec6ef 100644 --- a/node/src/rpc.rs +++ b/node/src/rpc.rs @@ -61,6 +61,7 @@ where TBackend: sc_client_api::Backend, // added by encointer >::OffchainStorage: 'static, // added by encointer { + use encointer_balances_tx_payment_rpc::{BalancesTxPaymentApiServer, BalancesTxPaymentRpc}; use frame_rpc_system::{System, SystemApiServer}; use pallet_encointer_bazaar_rpc::{BazaarApiServer, BazaarRpc}; use pallet_encointer_ceremonies_rpc::{CeremoniesApiServer, CeremoniesRpc}; @@ -72,6 +73,7 @@ where module.merge(System::new(client.clone(), pool, deny_unsafe).into_rpc())?; module.merge(TransactionPayment::new(client.clone()).into_rpc())?; + module.merge(BalancesTxPaymentRpc::new(client.clone()).into_rpc())?; module.merge(BazaarRpc::new(client.clone()).into_rpc())?; match backend.offchain_storage() {