Commit Graph

290 Commits

Author SHA1 Message Date
Svyatoslav Nikolsky ceefd1b05d remove account derivation functions (#1498) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 7d97e576d0 Remove without_storage_info for messages pallet (#1487)
* draft: remove without_storage_info for messages pallet

* some cleanup
2024-04-10 10:28:37 +02:00
Serban Iorga ec76490ddb Test pallet owner calls using macro
Define macro that generates tests for set_owner() and set_operating_mode()
in order to avoid duplicate code.

Signed-off-by: Serban Iorga <serban@parity.io>
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 852f629d78 Sync Westmint to Millau (#1482)
* sync Westmint to Millau

* "Westend parachains at Millau" dashboard
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky d11d9fd0b7 Parachain loop metrics (#1484)
* parachain loop metrics

* some fixes

* mini refactoring

* add tests
2024-04-10 10:28:37 +02:00
Serban Iorga f8ff3c9142 Unify the operating mode for bridge pallets (#1483)
Unify the operating mode for bridge pallets

- define the OperationMode trait and BasicOperatingMode enum
- use the OperationMode trait in all the bridge pallets
- use BasicOperatingMode instead of IsHalted for the Grandpa pallet
- use BasicOperatingMode as part of MessagesOperatingMode

Signed-off-by: Serban Iorga <serban@parity.io>
2024-04-10 10:28:37 +02:00
Serban Iorga ff342fafa9 Avoid duplicate function definitions
Avoid duplicate function definitions for:
- ensure_owner_or_root()
- ensure_not_halted()
- set_owner()
- set_operating_mode() / set_operational()

Signed-off-by: Serban Iorga <serban@parity.io>
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky a97dedb50f Store both block number and hash in best finalized storage value (#1475)
* store both block number and hash in BestFinalized

* also fix relay code

* spelling
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 31a2be845c Fix on-different-forks metrics during initialization (#1468)
* fix on-different-forks metrics during initialization

* "initialize" parachain finality pallet in on-demand parachains relay

* decrease converstion rate requests count

* more error logging

* fix compilation

* clippy
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 2f9d8e33e0 Add missing parts to rialto parachain bridge (part 1) (#1454)
* add proper parameter names to bridge declaration

* associate RialtoParachain token with DOT

* RialtoParachain<>Millau message pallet owners

* fix compilation
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 19c73ce0b7 Signed extension for rejecting obsolete messages pallet transactions (#1446)
* BridgeRejectObsoleteMessages

* add obsolete confirmations verification to the BridgeRejectObsoleteMessages

* move tests where they belong
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 631111ef7f fix clippy errors (#1447) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky b870fe74f8 Parachains pallet benchmarks (#1436)
* added parachains pallet benchmarks

* deduplicate insertion of bridged header

* pruning weight

* fixes

* fix compilation
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 5340ee5ab5 Added tracked parachains filter (#1432)
* added trackerd parachains filter + changed some docs

* fix compilation
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky f0d05de080 Get dispatch weight from the target chain (when DispatchFeePayment::AtTargetChain is used) (#1430)
* reintroduce From<SourceChain>InboundLaneApi

* impl From<Chain>InboundLaneApi for testnet runtimes

* use inboundlaneapi in relay

* remove unused OutboundXcmWeigher

* spelling

* added the only test to messages pallet

* fmt
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 7a92b40eab Fix clippy warnings + try to enable proper (no-warning) clippy on CI (#1410)
* fix clippy warnings

* try to reenable proper clippy on CI

* fix clippy error

* more Eqs

* ignore clippy::derive-partial-eq-without-eq - clippy seems to be broken now :/
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 542ebb5654 Complex RialtoParachain <> Millau relay (#1405)
* complex parachain relay

* fix spelling
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 5f2f61ced5 messages bridge between RialtoParachain and Millau (#1218) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 03c2f06a27 Parachains finality relay (#1199) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 748c265c47 Xcm in Rialto<>Millau bridge (#1379)
* add XCM pallet to Millau runtime

* some progress

* messages are delivered (no fee)

* temp

* flush

* flush

* some progress

* progress

* Trap(42) is dispatched successfully

* fix spelling

* no more manual sending

* parametrize weight credit for tests

* actually charge fees

* enable send-using-messages-pallet to keep our test deployments alive + send valid XCM sometimes

* fix benchmarks build

* fix tests
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky f54bd6c779 Parachains finality pallet (#1068)
* parachains finality

* parachains pallet test

* demo of how to configure GRANDPA pallet instance

* allow instances in parachains pallet

* spellcheck

* TODO + fix

* fmt

* removed invalid storage_keys file

* change all hashers to Blake2_128Concat

* use Twox64Concat for insertion position

* fix build

* fix compilation

* change ParaId and ParaHead types

* TODOs -> TODOs with issues refs
2024-04-10 10:28:37 +02:00
Sergei Shulepov e07b931476 Update spec_version for Rococo (#1387) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky d582061dff Remove support for encoded-call messaging from relay and runtime integration code (#1376)
* remove support for encoded-call messaging

* continue cleanup

* continue cleanup

* continue cleanup

* more cleanpup

* more cleanup

* fmt

* continue cleanup

* spellcheck

* rename

* fix benchmarks

* mention encoded-calls-messaging tag

* fixing deployments

* fix messages generation

* fmt
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky c538a39816 Switch to gav-xcm-v3 branch to be able to test bridges + XCMv3 integration (#1378)
* switch to gav-xcm-v3 branch (wip)

* add comment

* play with CI

* keep playing with CI

* play with CI

* trigger CI

* Revert "trigger CI"

This reverts commit fc35ac648fe6a3ea8e710a2e07dfee7d8762c6c4.
2024-04-10 10:28:37 +02:00
Adrian Catangiu d04b018630 Few typos and clippy fixes (#1362)
* fix typos

* clippy fixes
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 133934df7c fix parse_transaction on Rialto+Millau (#1360) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky c29bfcccc3 update chain versions (#1358) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 65c2c0ccce Update Substrate/Polkadot/Cumulus references (#1353)
* cumulus: 4e95228291
polkadot: 975e780ae0d988dc033f400ba822d14b326ee5b9
substrate: 89fcb3e4f62d221d4e161a437768e77d6265889e

* fix refs

* sync changes from https://github.com/paritytech/polkadot/pull/3828

* sync changes from https://github.com/paritytech/polkadot/pull/4387

* sync changes from https://github.com/paritytech/polkadot/pull/3940

* sync with changes from https://github.com/paritytech/polkadot/pull/4493

* sync with changes from https://github.com/paritytech/polkadot/pull/4958

* sync with changes from https://github.com/paritytech/polkadot/pull/3889

* sync with changes from https://github.com/paritytech/polkadot/pull/5033

* sync with changes from https://github.com/paritytech/polkadot/pull/5065

* compilation fixes

* fixed prometheus endpoint startup (it now requires to be spawned within tokio context)
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky ed2a3082ef Support dedicated lanes for pallets (#962)
* pass call origin to the message verifier

* is_outbound_lane_enabled -> is_message_accepted

* trait SenderOrigin

* only accept messages from token swap pallet to token swap lane

* tests for edge cases of pay_delivery_and_dispatch_fee

* fixed origin verification

* fmt

* fix benchmarks compilation

* fix TODO with None account and non-zero message fee (already covered by tests)

* revert cargo fmt changes temporarily
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky f95456d4ea replace From<>InboundLaneApi with direct storage reads (#1348) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 2bf5b23262 edition = "2021" (#1346) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 0ef401ae53 Revert "Revert "override conversion rate in estimate-message-fee RPC (#1189)" (#1275)" (#1333)
This reverts commit ffd25db46c5855bcef6710b53d5ca3325ce54e56.
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky bc1dcb7548 fix clippy issues (#1332) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 6f1c4f8beb impl Decode for SignedExtensions (otherwise transaction resubmitter panicks) (#1325) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky efa3e97210 Encode and estimate Rococo/Wococo/Kusama/Polkadot messages (#1322)
* encode and estimate Rococo/Wococo/Kusama/Polkadot messages

* allow send-message for non-bundled chains

* weight -> dispatch-weight

* fmt

* fix spelling
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 214febc46a expose fee multiplier metrics in messages relay (#1312) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky e190c35c95 fix session length of Rococo and Wococo (#1304) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky cb20c10bdb bump chain spec versions (#1297) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky ea2d6f898d Bump Substrate/Polkadot/Cumulus refs (#1295)
Substrate: 31d90c202d6df9ce3837ee55587b604619a912ba
Polkadot: 60df3c55c711c2872872d6220f98b2611340e051
Cumulus: a9630551c2
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 25008a5166 when messages pallet is halted, relay shall not submit messages delivery/confirmation transactions (#1289) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 0fa8c02e7a when GRANDPA pallet is halted, relay shall not submit finality transactions (#1288) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 1d99ad3619 replace latest_confirmed_nonce runtime APIs with direct storage reads (#1282) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 00f68e7722 Move benchmarks from Rialto to Millau (#1277)
* move brnchmarks from Rialto to Millau

* fix limits test
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky eb5a3eecd2 Revert "override conversion rate in estimate-message-fee RPC (#1189)" (#1275)
This reverts commit ad4299f6c91ce4c50cb6fbc739a0c788e2920956.
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky a88207876c Replace InboundLaneApi::latest_received_nonce with direct storage read (#1269)
* remove inbound_latest_received_nonce

* Update relays/lib-substrate-relay/src/messages_target.rs

Co-authored-by: Adrian Catangiu <adrian@parity.io>
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky bb249eff15 verify that GRANDPA pallet is not initialized before submitting initialization transaction (#1267)
* verify that GRANDPA pallet is not initialized before submitting initialization transaction

* spelling
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 988f6b1664 remove OutboundLaneApi::latest_received_nonce (#1262) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 13a3974f27 bump rococo version (#1263) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky c21217a282 read latest_generated_nonce directly from storage (#1260) 2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 741484214e override conversion rate in estimate-message-fee RPC (#1189) 2024-04-10 10:28:37 +02:00