Commit Graph

30 Commits

Author SHA1 Message Date
Rakan Alhneiti 2e521d30ea Companion PR to #5182 - Substrate offchain signing (#985)
* Implement offchain::SendTransactionTypes

* Fix test-runtime

* Fix Kusama

* Add SendTransactiontypes to Kusama

* impl SendTransactiontypes for parachains and registrar

* Fix typos

* Provided extrinsic type

* Implement AppCrypto for signing transactions

* Add signing capabilities to runtime

* Fix test runtimes

* Implement CreateSignedtransaction for Test

* Implement signing types for test runtimes

* Fix test runtime create transaction impl

* Fix build

* Bump kusama's spec version

* Update substrate

* Use all_accounts
2020-04-21 18:50:32 +02:00
Bastian Köcher 765c456a10 Fix building master (#1014)
* Fix building master

* Fix westend chainspec
2020-04-21 16:21:11 +02:00
Ashley 14766804c0 Remove usage of substrate-test-runtime. (#969)
* Switch from using the substrate_test_runtime Extrinsic to the polkadot_test_runtime one

* Copy genesismap into test-runtime

* Add UncheckedExtrinsics

* Fix tests :^)

* Remove unused functions from genesismap

* DRY, clean up

* Clean up

* Update service/src/grandpa_support.rs

Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com>

* Fix indentation

* Update runtime/test-runtime/src/genesismap.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
2020-04-21 12:56:22 +02:00
cheme 1a4db93c50 Companion to child trie api change #4857 (#950) 2020-04-21 10:39:35 +02:00
Bastian Köcher eab3624096 Release 0.7.30 (#1006)
* Release 0.7.30

* Update Substrate & libp2p
2020-04-17 23:01:00 +02:00
Gavin Wood e303f92f20 Companion for Runtime Semver (#987)
* Companion for Runtime Semver

* Fix
2020-04-17 12:10:58 +02:00
Fedor Sakharov cf7cf4bd7d Adds an offchain call to submit double vote reports (#966)
* Adds an offchain call to submit double vote reports

* Some tweaks

* Remove unnecessary IdentifyAccount impls

* Adds ValidateDoubleVoteReports to test runtime

* sp-application-crypto is only a dev dependency
2020-04-16 16:19:51 +01:00
Shawn Tabrizi 58f992fa33 Companion PR for substrate#5446 (Update Weights to u64) (#994) 2020-04-16 11:31:41 +02:00
Bastian Köcher c6134cf91a Release 0.7.29 (#998)
* Release 0.7.29

* Update `Cargo.lock`
2020-04-14 16:46:20 +02:00
Robert Habermeier a5034dbe98 Use strong types in runtime for parachain heads and validation code (#964)
* use stronger types for HeadData and ValidationCode in runtime

* fix weird debug compile error

* fix runtime build

* update invocations invalidation.rs

* fix tests
2020-04-13 10:24:25 +02:00
Pierre Krieger 75ebe7fb2e Companion PR to #5560 - Also includes polkadot#979 and polkadot#986 (#982)
* Companion PR to #5560

* Set priorities.

* Update substrate.

* Fix tests.

* Update Substrate

* Companion of SignedExtension refactor (#5540)

Co-authored-by: Tomasz Drwięga <tomasz@parity.io>
Co-authored-by: Alexander Theißen <alexander.theissen@parity.io>
2020-04-08 16:12:28 +02:00
Kian Paimani 011528278b Enable validate unsigned (#974) 2020-04-06 18:01:30 +02:00
Robert Habermeier 10cec3b591 Upgradeable validation functions (#918)
* upgrade primitives to allow changing validation function

* set up storage schema for old parachains code

* fix compilation errors

* fix test compilation

* add some tests for past code meta

* most of the runtime logic for code upgrades

* implement old-code pruning

* add a couple tests

* clean up remaining TODOs

* add a whole bunch of tests for runtime functionality

* remove unused function

* fix runtime compilation

* extract some primitives to parachain crate

* add validation-code upgrades to validation params and result

* extend validation params with code upgrade fields

* provide maximums to validation params

* port test-parachains

* add a code-upgrader test-parachain and tests

* fix collator tests

* move test-parachains to own folder to work around compilation errors

* fix test compilation

* update the Cargo.lock

* fix parachains tests

* remove dbg! invocation

* use new pool in code-upgrader

* bump lockfile

* link TODO to issue
2020-04-06 10:43:19 -04:00
Bastian Köcher c021f854a2 Ensure that table router is always built (#952)
* Ensure that table router is always build

This pr ensures that the table router is always build, aka the future is
resolved. This is important, as the table router internally spawns tasks
to handle gossip messages. Handling gossip messages is not only required
on parachain validators, but also on relay chain validators to receive collations.

Tests are added to ensure that the assumptions hold.

* Fix compilation

* Switch to closures

* Remove empty line

* Revert "Remove empty line"

This reverts commit 0d4aaba1780aec1c8d61e1d5dcf7768918af02d9.

* Revert "Switch to closures"

This reverts commit d128c4ecc02c911552a3bfd2142b5a4f7b1338ba.

* Hybrid approach

* Rename test

* Make trait crate local
2020-04-03 16:33:52 -04:00
Gavin Wood d8e1180030 Companion for #5412 (#942)
* Fixes for democracy using Scheduler

* Revert branch change
2020-04-01 17:01:14 +02:00
Bastian Köcher b4c79556f3 Upgrade bitvec and parity-scale-codec (#947) 2020-03-30 13:08:15 +02:00
Kian Paimani caa405e1eb Enable Offchain Phragmén. (#940)
* fix for offchain phragmen

* Update unix time stuff
2020-03-26 17:52:10 +01:00
thiolliere 775ce50cc2 Upgrade substrate for new staking API and Telemtry API (#941)
* upgrade substrate

* fix telemetry endpoint

* improve msg
2020-03-26 15:16:55 +01:00
Tomasz Drwięga c8150e1d33 Transaction source (#5366) companion PR (#938)
* Add transaction source.

* Bump substrate.

* Fix tests.
2020-03-26 10:38:01 +01:00
Fedor Sakharov dbb4e987fa Remove Parent Hash to Session mapping (#928)
* Adds a SigningContext type

* Bump spec versions

* Fixes requested changes

* Bump ParachainHost api_version and guard signing_context call

* Improve error message

* If there is no signing_context api use default value

Co-authored-by: Robert Habermeier <rphmeier@gmail.com>
2020-03-25 17:04:05 -04:00
thiolliere 62cddd6fcb Update substrate for new on_initialize syntax and update on_initialize weight (#937)
* update new on_initialize syntax

* update substrate

* update spec_version
2020-03-25 14:10:11 +01:00
Gav Wood 5f04e1aa52 Version bump 2020-03-23 16:29:10 +01:00
Fedor Sakharov 88ba024489 Parachains double vote handler initial implementation. (#840)
* Parachains double vote handler initial implementation.

* Make tests test the actual slashing.

* Implement SignedExtension validation of double vote reports.

* Fixes build after merge

* Review fixes

* Adds historical session proofs

* Review fixes.

* Bump runtime spec_version

* Get the session number from the proof

* Check that proof matches session

* Change signature type on DoubleVoteReport

* Adds docs and removes blank lines

* Removes leftover code

* Fix build

* Fix build after a merge

* Apply suggestions from code review

Co-Authored-By: Robert Habermeier <rphmeier@gmail.com>

* Prune ParentToSessionIndex

* Remove a clone and a warning

Co-authored-by: Robert Habermeier <rphmeier@gmail.com>
Co-authored-by: Gavin Wood <gavin@parity.io>
2020-03-22 09:48:35 +03:00
Gav Wood 0c435448f9 Bump version 2020-03-21 16:48:06 +01:00
Gavin Wood 95d732beca Introduce progressive democracy (#920)
* Updates for the new democracy

* Introduce progressive democracy

Also move to "master" branch of Substrate ready for continuous
sync with Substrate master.
2020-03-21 16:46:09 +01:00
Gavin Wood 6a7374aca3 Remove migration code. (#910)
* Remove migration code.

* Bump Substrate

* Bump runtime
2020-03-21 13:37:55 +01:00
André Silva 2edc7f13b0 Release version v0.7.27 (#916)
* bump version to v0.7.27

* update to latest substrate polkadot-master

* bump runtime impl_version
2020-03-19 16:24:32 +00:00
Gavin Wood a9a1034af5 Refactor storage hashing away from opaque types (#903)
* Refactor storage of various modules.

* The real list of claims

* Migration away from opaque maps

* Fix

* Fix for task executor API change
2020-03-17 11:54:13 +01:00
Gavin Wood 1ddfb5c4e1 Bump to latest Substrate (#898)
* Flag to force kusama runtime

* Chainspecs for kusama

* Polkadot config for westend

Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com>

* network/src/legacy/gossip: Wrap GossipEngine in Arc Mutex & lock it on use

`GossipEngine` in itself has no need to be Send and Sync, given that it
does not rely on separately spawned background tasks anymore.
`RegisteredMessageValidator` needs to be `Send` and `Sync` due to the
inherited trait bounds from implementing `GossipService`. In addition
`RegisteredMessageValidator` derives `Clone`. Thereby `GossipEngine`
needs to be wrapped in an `Arc` and `Mutex` to keep the status quo.

* Needed fixes.

* Fixes

* Fixed build

* Fixed build w benchmarking CLI

* Fixed building tests

* Added --dev shortcut

Co-authored-by: arkpar <arkady.paronyan@gmail.com>
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: Max Inden <mail@max-inden.de>
2020-03-13 14:43:31 +01:00
Ashley 1736c2d576 Add a testnet similar to sc_network_test. (#852)
* Copy over files

* Most network tests work

* Fix copyrights

* Strip out unneeded pallets

* Update test-runtime and remove unused network test things

* Upgrade test runtime

* Strip more things out of the test runtime

* Bump kusama impl version
2020-03-10 15:36:21 +01:00