- Aug 02, 2021
-
-
Arkadiy Paronyan authored
* Started warp sync * BABE & GRANDPA recovery * Warp sync protocol * Sync warp proofs first * Added basic documentation * Apply suggestions from code review Co-authored-by: André Silva <[email protected]> * Style changes * Apply suggestions from code review Co-authored-by: André Silva <[email protected]> * fmt * Apply suggestions from code review Co-authored-by: André Silva <[email protected]> * Fixed chage trie pruning wrt missing blocks * Restore parent finalization * fmt * fmt * Revert pwasm-utils bump * Change error type & check API version * Apply suggestions from code review Co-authored-by: Bastian Köcher <[email protected]> * Build fix * Fixed target block check * Formatting Co-authored-by: André Silva <[email protected]> Co-authored-by: Bastian Köcher <[email protected]>
-
- Jul 30, 2021
-
-
Squirrel authored
* moved client code out of primitives * bump ci * Fixup from merge. * Removed unused deps thanks to review feedback * Removing unneeded deps * updating lock file * note about rustfmt * fixed typo to bump ci * Move lonely CacheKeyId to parent * cargo fmt * updating import style * Update docs/STYLE_GUIDE.md Co-authored-by: André Silva <[email protected]> Co-authored-by: André Silva <[email protected]>
-
- Jul 26, 2021
-
-
Squirrel authored
Taking best bits of rustfmt's format_strings Co-authored-by: Alexander Popiak <[email protected]>
-
- Jul 22, 2021
-
-
Squirrel authored
* Remove extra commas made redundent after rustfmt
-
- Jul 21, 2021
-
-
Bastian Köcher authored
* Run cargo fmt on the whole code base * Second run * Add CI check * Fix compilation * More unnecessary braces * Handle weights * Use --all * Use correct attributes... * Fix UI tests * AHHHHHHHHH *
🤦 * Docs * Fix compilation *🤷 * Please stop *🤦 x 2 * More * make rustfmt.toml consistent with polkadot Co-authored-by: André Silva <[email protected]>
-
- Jul 14, 2021
-
-
Liu-Cheng Xu authored
* Impl InherentDataProviderExt for more tuples Currently the inherent data provider only supports up to 4 entries due to the limit of InherentDataProviderExt, which is not enough for a chain with more than 4 inherent data providers. This patch simply impls InherentDataProviderExt for more tuples. * Nit * Apply suggestions from code review Co-authored-by: André Silva <[email protected]> Co-authored-by: Guillaume Thiolliere <[email protected]> Co-authored-by: André Silva <[email protected]>
-
- Jul 13, 2021
-
-
dependabot[bot] authored
Bumps [async-trait](https://github.com/dtolnay/async-trait) from 0.1.48 to 0.1.50. - [Release notes](https://github.com/dtolnay/async-trait/releases) - [Commits](https://github.com/dtolnay/async-trait/compare/0.1.48...0.1.50) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
-
dependabot[bot] authored
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.124 to 1.0.126. - [Release notes](https://github.com/serde-rs/serde/releases) - [Commits](https://github.com/serde-rs/serde/compare/v1.0.124...v1.0.126) --- updated-dependencies: - dependency-name: serde dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
-
- Jul 12, 2021
-
-
Seun Lanlege authored
* better apis * .... * ... * Genensis -> UnimportedGenesis * adds rpc for runtime upgrades * simplify test-runner * clean up test-runner api * remove unused imports * fix doc-test * fix line width * correct Node::clean * correct Node::clean * add deny rules * remove unused extern crates * remove mutex from node * Update test-utils/test-runner/Cargo.toml Co-authored-by: Andronik Ordian <[email protected]> * adds docs, removes Node::clean Co-authored-by: Andronik Ordian <[email protected]> Co-authored-by: Seun Lanlege <[email protected]>
-
- Jul 11, 2021
-
-
Benjamin Kampmann authored
* mark template and utils as non-publish * switch to development version for testing * activate unleash check * maybe if I disable all rules... * Fix isolated compilation of `max-encoded-len-derive` with `syn` error[E0369]: binary operation `==` cannot be applied to type `syn::Path` --> src/lib.rs:88:29 | 88 | .filter(|attr| attr.path == parse_quote!(max_encoded_len_crate)) | --------- ^^ ----------------------------------- _ | | | syn::Path error: aborting due to previous error For more information about this error, try `rustc --explain E0369`. Error: could not compile `max-encoded-len-derive` * WIP: bump changes crates since v3 tag to next breaking cargo unleash version bump-breaking --changed-since v3.0.0 cargo unleash version set-pre dev --changed-since v3.0.0 FIXME: Don't modify crates that are not yet released, e.g. `max-encoded-len-derive` * Update lockfile * WIP: Bump sp-transaction-pool as well * WIP: Bump sp-offchain as well * WIP: Bump frame-system-rpc-runtime-api as well * WIP: Bump sp-authority-discovery as well * Manually deactivate dev-deps before `cargo unleash check` Otherwise we run into `Cycle detected` error. * Bump sp-consensus-slots * Add missing Cargo.lock change * Bump sp-consensus-vrf as well * Bump sp-keyring as well * Bump sp-consensus-pow as well * Try to speed up the `unleash-check` job Previously, the job took 106 minutes - let's see if explicitly specifying a `CARGO_TARGET_DIR` will help * fixup: Ensure the temp target dir exists for unleash check * Bump pallet-transaction-payment-rpc-runtime-api as well Needed for Polkadot * Bump pallet-transaction-payment-rpc as well Needed for Polkadot * Try updating crates after patching in the Polkadot CI job * Use another approach to update patched Substrate crates * Try to update all sp-core versions in Polkadot CI job * Simplify sp-core version checking * Apply another shellcheck lint * Just do the simplest thing I guess * Welp don't do --offline then * Clean up `unleash-check` job triggers Co-authored-by: Denis Pisarev <[email protected]> * Fix a note in unleash-check cache step * Add a note about temporary optimization in cargo-unleash * Pin a newer version of cargo-unleash Co-authored-by: Igor Matuszewski <[email protected]> Co-authored-by: Denis Pisarev <[email protected]>
-
- Jul 08, 2021
-
-
Seun Lanlege authored
* Use TransactionPool trait * sc-transaction-pool-primitives * sc-transaction-pool-api * TP * bye sc_transaction_graph * fix line widths * fix import errors * fix import errors * fix import errors
🤦🏾 ♂️ * fix import errors🤦🏾 ♂️🤦🏾 ♂️🤦🏾 ♂️ * remove sp-keyring
-
- Jun 29, 2021
-
-
Ashley authored
Remove `txpool` as an export of `sc_transaction_pool`, exporting the used components instead. (#9217) * Remove `txpool` as an export of `sc_transaction_pool`, exporting the used components instead. * Fix tests
-
- Jun 24, 2021
-
-
Squirrel authored
* Use MAX associated const
-
- Jun 22, 2021
-
-
Arkadiy Paronyan authored
* State sync * Importing state fixes * Bugfixes * Sync with proof * Status reporting * Unsafe sync mode * Sync test * Cleanup * Apply suggestions from code review Co-authored-by: cheme <[email protected]> Co-authored-by: Pierre Krieger <[email protected]> * set_genesis_storage * Extract keys from range proof * Detect iter completion * Download and import bodies with fast sync * Replaced meta updates tuple with a struct * Fixed reverting finalized state * Reverted timeout * Typo * Doc * Doc * Fixed light client test * Fixed error handling * Tweaks * More UpdateMeta changes * Rename convert_transaction * Apply suggestions from code review Co-authored-by: Bastian Köcher <[email protected]> * Apply suggestions from code review Co-authored-by: Bastian Köcher <[email protected]> * Code review suggestions * Fixed count handling Co-authored-by: cheme <[email protected]> Co-authored-by: Pierre Krieger <[email protected]> Co-authored-by: Bastian Köcher <[email protected]>
-
- Jun 20, 2021
-
-
André Silva authored
* make SelectChain async * make JustificationImport async
-
- Jun 19, 2021
-
-
André Silva authored
* aura, babe: proposal slot lenience must take into account proposal portion * slots: add support for max_block_proposal_slot_portion * fix compilation * slots: add tests * aura: fix comment Co-authored-by: Bastian Köcher <[email protected]> * slots: log the actual proposing duration after lenience is applied Co-authored-by: Bastian Köcher <[email protected]>
-
André Silva authored
* babe: add comments to block weight and expose block_weight function * babe: expose function for block weight key
-
- Jun 17, 2021
-
-
Bastian Köcher authored
This instructs the Aura runtime api to skip initialize block, when requesting the authorities. This is important, as we don't want to use the new authorities that should be used from the next block on. Besides that, it removes the caching stuff. The cache is not available on full nodes anyway. In the future we should store the authorities probably in the aux store.
-
- Jun 04, 2021
-
-
André Silva authored
* consensus: add trait to control justification sync process * network: implement JustificationSyncLink for NetworkService * slots: handle justification sync in slot worker * babe: fix slot worker instantiation * aura: fix slot worker instantiation * pow: handle justification sync in miner * babe: fix tests * aura: fix tests * node: fix compilation * node-template: fix compilation * consensus: rename justification sync link parameter * aura: fix test compilation * consensus: slots: move JustificationSyncLink out of on_slot
-
- Jun 02, 2021
-
-
Bastian Köcher authored
`ready_at` returns when we have processed the requested block. However, on startup we already have processed the best block and there are no transactions in the pool on startup anyway. So, we can set `updated_at` to the best block on startup. Besides that `ready_at` now returns early when there are no ready nor any future transactions in the pool.
-
- Jun 01, 2021
-
-
Squirrel authored
Co-authored-by: Bastian Köcher <[email protected]>
-
- May 31, 2021
-
-
Seun Lanlege authored
* use correct CreateInherentDataProviders impl for manual seal * add babe inherent provider * move client into factory fn
-
dependabot[bot] authored
Bumps [retain_mut](https://github.com/upsuper/retain_mut) from 0.1.2 to 0.1.3. - [Release notes](https://github.com/upsuper/retain_mut/releases) - [Commits](https://github.com/upsuper/retain_mut/compare/v0.1.2...v0.1.3) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
-
- May 22, 2021
-
-
Bastian Köcher authored
* Aura: Expose function to build the verifier * Use best block to initialize the authorities cache * Use best block when determining the slot duration * Remove `AuraBlockImport` * Some cleanups * Fix build error
-
- May 11, 2021
-
-
Wei Tang authored
* pow: fix docs on mining worker * typo: miner -> mining * Switch to proper Rust intra-doc link
-
- May 06, 2021
-
-
Bastian Köcher authored
* Fix the calculation of the time until the next slot * Update client/consensus/slots/src/slots.rs Co-authored-by: André Silva <[email protected]> Co-authored-by: André Silva <[email protected]>
-
- May 03, 2021
-
-
Bastian Köcher authored
* Lol * Yeah * Moare * adaasda * Convert AURA to new pallet macro * AURA: Switch to `CurrentSlot` instead of `LastTimestamp` This switches AURA to use `CurrentSlot` instead of `LastTimestamp`. * Add missing file * Update frame/aura/src/migrations.rs Co-authored-by: André Silva <[email protected]> * Remove the runtime side provide inherent code * Use correct weight * Add TODO * Remove the Inherent from AURA *
🤦 * Remove unused stuff * Update primitives authorship * Fix babe inherent data provider * Fix consensus-uncles * Fix BABE * Do some further changes to authorship primitives... :D * More work * Make it compile the happy path * Make it async! * Take hash * More stuff * Hacks * Revert "Hacks" This reverts commit cfffad88668cfdebf632a59c4fbfada001ef8251. * Fix * Make `execute_block` return the final block header * Move Aura digest stuff * Make it possible to disable equivocation checking * Fix fix fix * Some refactorings * Comment * Fixes fixes fixes * More cleanups * Some love * Better love * Make slot duration being exposed as `Duration` to the outside * Some slot info love * Add `build_aura_worker` utility function * Copy copy copy * Some stuff * Start fixing pow * Fix pow * Remove some bounds * More work * Make grandpa work * Make slots use `async_trait` * Introduce `SharedData` * Add test and fix bugs * Switch to `SharedData` * Make grandpa tests working * More Babe work * Make grandpa work * Introduce `SharedData` * Add test and fix bugs * Switch to `SharedData` * Make grandpa tests working * More Babe work * Make it async * Fix fix * Use `async_trait` in sc-consensus-slots This makes the code a little bit easier to read and also expresses that there can always only be one call at a time to `on_slot`. * Make grandpa tests compile * More Babe tests work * Fix network test * Start fixing service test * Finish service-test * Fix sc-consensus-aura * Fix fix fix * More fixes * Make everything compile *yeah* * Make manual-seal compile * More fixes * Start fixing Aura * Fix Aura tests * Fix Babe tests * Make everything compile * Move code around and switch to async_trait * Fix Babe * Docs docs docs * Move to FRAME * Fix fix fix * Make everything compile * Last cleanups * Fix integration test * Change slot usage of the timestamp * We really need to switch to `impl-trait-for-tuples` * Update primitives/inherents/src/lib.rs Co-authored-by: André Silva <[email protected]> * Update primitives/inherents/src/lib.rs Co-authored-by: André Silva <[email protected]> * Update primitives/inherents/src/lib.rs Co-authored-by: André Silva <[email protected]> * Some extra logging * Remove dbg! * Update primitives/consensus/common/src/import_queue/basic_queue.rs Co-authored-by: André Silva <[email protected]> Co-authored-by: André Silva <[email protected]>
-
- Apr 23, 2021
-
-
François Garillot authored
* Simplify some Option / Result / ? operator patterns When those match a combinator exactly. Tool-aided by [comby-rust](https://github.com/huitseeker/comby-rust). * adjust after review * adjust post-review
-
- Apr 19, 2021
-
-
André Silva authored
-
- Apr 14, 2021
-
-
Bastian Köcher authored
* Introduce a "dynamic" block size limit for proposing This adds support for using a dynamic block size limit per call to `propose`. This is required for Cumulus/Parachains to always use stay in the limits of the maximum allowed PoV size. As described in the docs, the block limit is only checked in the process of pushing transactions. As we normally do some other operations in `on_finalize`, it can happen that the block size still grows when there is some proof being collected (as we do for parachains). This means, that the given block limit needs to be rather conservative on the actual value and should not be the upper limit. * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: Andronik Ordian <[email protected]> * More future proof encoded size updating * Use `ProofRecorderInner` * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: André Silva <[email protected]> * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: André Silva <[email protected]> * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/slots/src/lib.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/slots/src/slots.rs Co-authored-by: André Silva <[email protected]> * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: André Silva <[email protected]> * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: André Silva <[email protected]> * Update client/basic-authorship/src/basic_authorship.rs Co-authored-by: André Silva <[email protected]> Co-authored-by: Andronik Ordian <[email protected]> Co-authored-by: André Silva <[email protected]>
-
- Mar 30, 2021
-
-
Bastian Köcher authored
* Make grandpa work * Introduce `SharedData` * Add test and fix bugs * Switch to `SharedData` * Make grandpa tests working * More Babe work * Make it async * Fix fix * Use `async_trait` in sc-consensus-slots This makes the code a little bit easier to read and also expresses that there can always only be one call at a time to `on_slot`. * Make grandpa tests compile * More Babe tests work * Fix network test * Start fixing service test * Finish service-test * Fix sc-consensus-aura * Fix fix fix * More fixes * Make everything compile *yeah* * Fix build when we have Rust 1.51 * Update client/consensus/common/src/shared_data.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/common/src/shared_data.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/common/src/shared_data.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/common/src/shared_data.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/common/src/shared_data.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/babe/src/tests.rs Co-authored-by: André Silva <[email protected]> * Update client/consensus/babe/src/tests.rs Co-authored-by: André Silva <[email protected]> * Fix warning Co-authored-by: André Silva <[email protected]>
-
Bastian Köcher authored
This is not really required and having a special `test-helpers` feature is a bad idea anyway.
-
- Mar 27, 2021
-
-
Bastian Köcher authored
* Use `async_trait` in sc-consensus-slots This makes the code a little bit easier to read and also expresses that there can always only be one call at a time to `on_slot`. * slots: remove mutex around BlockImport in SlotWorker Co-authored-by: André Silva <[email protected]>
-
- Mar 17, 2021
-
-
Bastian Köcher authored
* Make slot duration being exposed as `Duration` to the outside * Some slot info love * Add `build_aura_worker` utility function * Copy copy copy
-
Jon Häggblad authored
* primitives/runtime: initial changes on supporting multiple Justifications * primitives/runtime: make Justifications strongly typed * Encode/decode Justifications * primitives/runtime: add Justification type * backend: apply_finality and finalize_block takes a single Justification * manual-seal: create engine id and let rpc take encoded justification * backend: skeleton functions for appending justifications * backend: initial implementation append_justification Initial implementation of append_justification on the Backend trait, and also remove unused skeleton functions for append_justificaton on Finaziler trait. k * backend: guard against duplicate consensus engine id * client/db: add check for block finality * client/api: add append_justification to in_mem db * client/light: add no-op append_justification * network: fix decode call for Justification * network: only send a single Justification in BlockData * network: minor comment update * protocol: update field names to distinguish single justification * client: further field renames to plural * client: update function names to plural justifications * client/db: upgrade existing database for new format * network: remove dependency on grandpa crate * db: fix check for finalized block * grandpa: check for multiple grandpa justifications hwne importing * backend: update Finalizer trait to take multiple Justifications * db: remove debugging statements in migration code * manual-seal: update note about engine id * db: fix check for finalized block * client: update variable name to reflect it is now plural * grandpa: fix incorrect empty Justications in test * primitives: make Justifications opaque to avoid being empty * network: fix detecting empty Justification * runtime: doc strings for Justifications functions * runtime: add into_justifications * primitives: check for duplicates in when adding to Justifications * network/test: use real grandpa engine id in test * client: fix reviewer comments * primitives: rename Justifications::push to append * backend: revert changes to Finalizer trait * backend: revert mark_finalized * backend: revert changes to finalize_block * backend: revert finalized_blocks * db: add a quick early return for performance * client: minor reviewer comments * service/test: use local ConsensusEngineId * network: add link to issue for sending multiple Justifications * Apply suggestions from code review Co-authored-by: Pierre Krieger <[email protected]> * Apply suggestions from code review Co-authored-by: Pierre Krieger <[email protected]> * network: tweaks to review suggestions * network: revert change to BlockData for backwards compatibility * Apply suggestion from code review Co-authored-by: Pierre Krieger <[email protected]> * Apply suggestions from code review Co-authored-by: André Silva <[email protected]> * primitives: update doc comment for Justifications * client/db/upgrade: avoid grandpa crate dependency * consensus: revert to single Justification for import_justification * primitives: improve justifications docs * style cleanups * use and_then * client: rename JUSTIFICATIONS db column * network: revert to using FRNK in network-test Co-authored-by: Pierre Krieger <[email protected]> Co-authored-by: André Silva <[email protected]> Co-authored-by: André Silva <[email protected]>
-
- Mar 11, 2021
-
-
Bastian Köcher authored
The timestamp inherent type was up to now just a simple `u64`. This worked, but doesn't give you that much guarantees at compile time about the type. This pr changes that by converting this type to a unit type wrapper, similar to what we have done for `Slot`. This is required for some future pr that touches quite a lot of the inherents stuff :) Besides this unit wrapper type, this pr also moves the `OnTimestampSet` trait to `frame_support::traits`.
-
Cecile Tonglet authored
polkadot companion: paritytech/polkadot#2535
-
- Mar 10, 2021
-
-
Ashley authored
* Make changes * Add serialize/deserialize, copy babe epoch config defaults from node runtime * Fix line widths and turn default features off for serde * Remove ser/deser from Epoch, fix node-cli * Apply suggestions * Add comment to BABE_GENESIS_EPOCH_CONFIG in bin * Apply suggestions * Add a sketchy migration function * Add a migration test * Check for PendingEpochConfigChange as well * Make epoch_config in node-cli * Move updating EpochConfig out of the if * Fix executor tests * Calculate weight for add_epoch_configurations * Fix babe test * Apply suggestions from code review Co-authored-by: André Silva <[email protected]> * Add more asserts to tests, remove unused changes to primitives/slots * Allow setting the migration pallet prefix * Rename to BabePalletPrefix Co-authored-by: André Silva <[email protected]>
-
- Mar 09, 2021
-
-
Bastian Köcher authored
* Introduce new concept of "slot portion for proposing" Currently when building a block we actually give the proposer all of the time in the slot, while this is wrong. The slot is actually split in at least two phases proposing and propagation or in the polkadot case into three phases validating pov's, proposing and propagation. As we don't want to bring that much polkadot concepts into Substrate, we only support splitting the slot into proposing and propagation. The portion can now be passed as parameter to AuRa and BABE to configure this value. However, this slot portion for propagation doesn't mean that the proposer can not go over this limit. When we miss slots we still apply the lenience factor to increase the proposing time, so that we have enough time to build a heavy block. Besides all what was said above, this is especially required for parachains. Parachains have a much more constraint proposing window. Currently the slot duration is at minimum 12 seconds, but we only have around 500ms for proposing. So, this slot portion for proposing is really required to make it working without hacks. * Offgit feedback * Cast cast cast
-
Liu-Cheng Xu authored
-