Commit Graph

29 Commits

Author SHA1 Message Date
Svyatoslav Nikolsky d63a75697c Only store header state root (pallet-bridge-parachains) (#1701)
* store block number ++ state root in parachains pallet

* fixed parachains finality APIs

* (test commit)

* removed test code

* deduplicated code a bit

* removed commented code

* spelling

* Update modules/parachains/src/lib.rs

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* Update modules/parachains/src/lib.rs

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* Update modules/parachains/src/mock.rs

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* added comment

Co-authored-by: Adrian Catangiu <adrian@parity.io>
2024-04-10 10:28:37 +02:00
Serban Iorga 01538bc5fa Finality loop: get block justification and authorities change by consensus engine ID (#1619)
* SignedBlock: get justification by consensus engine id

* Define ConsensusLogReader

Making the check for authority changes more generic

* cod review changes
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky f58e076ca2 fixes for nightly clippy (#1618) 2024-04-10 10:28:37 +02:00
Serban Iorga 597ea49664 Finality loop - cosmetic changes (#1609)
* Move some logic to RestartableFinalityProofsStream

* Move some logic to `Transaction`

* Avoid unnecessary split_off
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 9e1847d12a Fix new nightly clippy issues (#1604)
* clipy

* revert some fixes that newest clippy reports as issues, but older does not
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 43afa02372 Read extrinsic dispatch result for mined transaction (#1582)
* read extrinsic dispatch result for mined transaction

* commit for the history

* Revert "commit for the history"

This reverts commit 99341b04750639db296172cc1432bd70e458ef4b.

* Revert "read extrinsic dispatch result for mined transaction"

This reverts commit 662b776cbf992be9f1637e52f023b782e8c441d1.

* check for successfult transaction in finality relay

* check for successful transaction in parachains relay

* TrackedTransactionStatus ->TrackedTransactionStatus<HeaderId>

* check for successful transaction in messages relay

* fix compilation

* message_lane_loop_is_able_to_recover_from_unsuccessful_transaction

* fixed too-complex-type clippy error

* aaand compilation
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 70d6e91f20 TransactionInvalidationTracker (#1544)
* TransactionInvalidationTracker

* TransacitonInvalidationTracker -> TransactionTracker

* change sign_transaction method

* clippy and spelling

* removed comment

* more transactiontracker tests

* stalls_when_transaction_tracker_returns_error

* remove test code

* remove "impl TransactionTracker for ()"

* enum TrackedTransactionStatus

* test TransactionTracker in on_transaction_status

* do_wait
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky f35b4f4897 Extract unsigned tx from the SignParam structure (#1561)
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
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 e29b590785 Using-same-fork metric for finality and complex relay (#1327)
* using_same_fork metric in finality relay

* support `using_different_forks` in messages relay

* added dashboards and alerts

* lockfile
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky bbf8b51f9c Unify metric names (#1209)
* unify metric names

* refactor standalone metrics

* headers sync metrics

* post-merge fix

* fix compilation

* fmt

* fix dashboards

* fix local dashboards

* update Rococo/Wococo runtime version

* remove commented code

* fixed grumbles

* fmt

* fixed widget names
2024-04-10 10:28:37 +02:00
Adrian Catangiu 2a6b065a91 Remove unused relays/headers (#1216)
* Decouple `relays/client-substrate` from `headers_relay`
* Remove `blocks_in_state` from `SyncLoopMetrics`
    This metric was only relevant for PoA <> Substrate bridge.
* Move `sync_loop_metrics.rs` to `relays/finality`
* Remove unused `SyncLoopMetrics::update()`
* Hook up SyncLoopMetrics to finality_loop
* Delete now unused `relays/headers`

Signed-off-by: acatangiu <adrian@parity.io>
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky c2b38ba530 fix clippy things (#1200) 2024-04-10 10:28:37 +02:00
Vladislav 5842968273 Unify error enums in substrate and ethereum clients with thiserror (#1094)
* Unify error enums in substrate and ethereum clients with `thiserror`

Related to https://github.com/paritytech/parity-bridges-common/issues/857

* Add license pre-amble

* rustfmt

* Fix spelling
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 44a6416ffc additional log in finality relay + rephrase "failed" (#1182) 2024-04-10 10:28:37 +02:00
hacpy bd70de8b8b Match substrate's fmt (#1148)
* Alter gitlab.

* Use substrate's rustfmt.toml

* cargo +nightly fmt --all

* Fix spellcheck.

* cargo +nightly fmt --all

* format.

* Fix spellcheck and fmt

* fmt?

* Fix spellcheck

Co-authored-by: Tomasz Drwięga <tomasz@parity.io>
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 6e3b083ab3 Fix spelling (#1118)
* I'm just trying to do my job

* spelling
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 69d41127bc Fix Westend -> Millau sync (#1064)
* read justifications from stream using channel + task that fills that channel

* Arc<Mutex> -> Mutex
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky ecd20d9d24 Shared reference to conversion rate metric value (#1034)
* shared conversion rate metric value

* clippy
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky c69c682a4c Add --only-mandatory-headers mode (#1004) 2024-04-10 10:28:37 +02:00
Denis Pisarev 0b7f40a371 Move CI from GitHub Actions to GitLab (#814)
* CI: do not trust this CI 1

* CI: don't want to trigger unneded statuses

* CI: debug 1

* CI: new CI

* CI: temp allow failure

* CI: exclude paths

* doc: check if docs won't trigger pipelines

* doc: check hybrid changes pipeline

* doc: do not push excluded files together with others

* CI: undebug fmt

* CI: better deny

* CI: fix deny and spellcheck

* CI: global backtrace

* CI: deny config

* CI: publishing

* Dockerfile: metadata fix [skip ci]

* CI: revert me

* CI: debug bash

* CI: mv ci.Dockerfile; fix buildah bug

* CI: fix artifact name

* Dockerfile: fix context

* CI: separate deny check licenses

* CI: when to run

* CI: unneded stuff in these Dockerfiles

* CI: merged test-refs and build-refs

* CI: test-build optimizations

* CI: changes, web, scheduled pipelines now work as intended

* CI: use tested production CI image

* CI: substitute GHA

* Fix clippy.

* Moar clippy fixes.

* Fix more.

* Finally fix all?

Co-authored-by: Tomasz Drwięga <tomasz@parity.io>
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 6301ae0636 Always run on-demand headers relay in complex relay (#975)
* always run on-demand headers relay in complex relay

* fix compilation
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 38cd3a328d Do not spawn additional task for on-demand relays (#933)
* do not spawn additional task for on-demand relays

* compilation
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky 63ce1b5973 Prefix in relay loops logs (#920)
* prefix in relay loops logs

* fmt
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky e2131724fb Complex headers+messages Millau<->Rialto relay (#878)
* complex headers+messages relay

* post-merge fix

* fix + test issue with on-demand not starting
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky cb90ea0979 Pre-create metrics registry before loop is started + administrative metrics (#848)
* administrative metrics

* fmt

* fix compilation

* fix compilation again

* and another one

* remove GenericLoopMetrics

* chttp -> isahc

* remove redundant marker

* not about price metrics

* fmt
2024-04-10 10:28:37 +02:00
Hernando Castano 67cdca8aa4 Use GrandpaJustification instead of Vec<u8> in Pallet API (#847)
* Stop passing raw encoded justifications to pallet API

By having the API accept a struct-ified justification we are able to
better utilize the justifications fields for weight calculations.

* Update relayer code to use decoded justifications

* Add justification to `expect()` statement

* Fix some imports

* Make justification wrapper contain decoded justification

* Rename some fields

* Get rid of warnings

* Appease Clippy

* Only decode justification once at init time

* Remove unnecessary method

* Remove justification wrapper

This became kinda unnecessary since we could implement the FinalityProof
trait on GrandpaJustification directly.
2024-04-10 10:28:37 +02:00
Svyatoslav Nikolsky a17c7eb80c Changed how relay loops are started (#840)
* slightly changed relay loop initialization

* git mv

* clippy

* more clippy

* loop_run -> run_loop

* review and clippy

* clippy
2024-04-10 10:28:37 +02:00
Tomasz Drwięga acb872fbb0 Flatten back the structure (#837)
* Remove chains.

* Move relay clients.

* Flatten generic.

* Fix fmt.
2024-04-10 10:28:37 +02:00