Skip to content
  1. Sep 27, 2023
    • Michal Kucharczyk's avatar
      `BlockId` removal: `tx-pool` refactor (#1678) · ab3a3bc2
      Michal Kucharczyk authored
      
      
      It changes following APIs:
      - trait `ChainApi`
      -- `validate_transaction`
      
      - trait `TransactionPool` 
      --`submit_at`
      --`submit_one`
      --`submit_and_watch`
      
      and some implementation details, in particular:
      - impl `Pool` 
      --`submit_at`
      --`resubmit_at`
      --`submit_one`
      --`submit_and_watch`
      --`prune_known`
      --`prune`
      --`prune_tags`
      --`resolve_block_number`
      --`verify`
      --`verify_one`
      
      - revalidation queue
      
      All tests are also adjusted.
      
      ---------
      
      Co-authored-by: command-bot <>
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      ab3a3bc2
  2. Aug 23, 2023
  3. Aug 17, 2023
  4. May 02, 2023
  5. Mar 07, 2023
  6. Feb 21, 2023
    • Vivek Pandya's avatar
      Remove years from copyright notes. (#13415) · bc53b9a0
      Vivek Pandya authored
      * Change copyright year to 2023 from 2022
      
      * Fix incorrect update of copyright year
      
      * Remove years from copy right header
      
      * Fix remaining files
      
      * Fix typo in a header and remove update-copyright.sh
      bc53b9a0
  7. Dec 20, 2022
    • Michal Kucharczyk's avatar
      `BlockId` removal: refactor: `HeaderBackend::header` (#12874) · 548955a7
      Michal Kucharczyk authored
      * BlockId removal: refactor: HeaderBackend::header
      
      It changes the arguments of:
      - `HeaderBackend::header`,
      - `Client::header`,
      - `PeersClient::header`
      - `ChainApi::block_header`
      
      methods from: `BlockId<Block>` to: `Block::Hash`
      
      This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292)
      
      * non-trivial usages of haeder(block_id) refactored
      
      This may required introduction of dedicated function:
      header_for_block_num
      
      * fmt
      
      * fix
      
      * doc fixed
      
      * ".git/.scripts/fmt.sh"
      
      * BlockId removal: refactor: HeaderBackend::expect_header
      
      It changes the arguments of `HeaderBackend::expect_header` method from: `BlockId<Block>` to: `Block::Hash`
      
      * ".git/.scripts/fmt.sh"
      
      * readme updated
      
      * ".git/.scripts/fmt.sh"
      
      * fix
      
      Co-authored-by: parity-processbot <>
      548955a7
  8. Dec 14, 2022
  9. Oct 11, 2022
  10. Sep 25, 2022
  11. Aug 15, 2022
  12. Jul 29, 2022
  13. Jan 10, 2022
  14. Jan 05, 2022
  15. Jan 03, 2022
  16. Aug 24, 2021
  17. Aug 11, 2021
  18. Aug 02, 2021
  19. Jul 30, 2021
  20. Jul 21, 2021
    • Bastian Köcher's avatar
      Run cargo fmt on the whole code base (#9394) · 7b56ab15
      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: default avatarAndré Silva <[email protected]>
      7b56ab15
  21. Jul 08, 2021
    • Seun Lanlege's avatar
      sc-transcation-pool refactor (#9228) · 2ae9d367
      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
      2ae9d367
  22. Jun 29, 2021
  23. Jun 02, 2021
    • Bastian Köcher's avatar
      Transactionpool: Make `ready_at` return earlier (#8995) · 2ab5f9ae
      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.
      2ab5f9ae
  24. May 03, 2021
    • Bastian Köcher's avatar
      Rework inherent data client side (#8526) · 2675741a
      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: default avatarAndré 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: default avatarAndré Silva <[email protected]>
      
      * Update primitives/inherents/src/lib.rs
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      
      * Update primitives/inherents/src/lib.rs
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      
      * Some extra logging
      
      * Remove dbg!
      
      * Update primitives/consensus/common/src/import_queue/basic_queue.rs
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      2675741a
  25. Mar 30, 2021
  26. Mar 17, 2021
    • Jon Häggblad's avatar
      Storing multiple Justifications per block (#7640) · 0d6884b9
      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: default avatarPierre Krieger <[email protected]>
      
      * Apply suggestions from code review
      
      Co-authored-by: default avatarPierre Krieger <[email protected]>
      
      * network: tweaks to review suggestions
      
      * network: revert change to BlockData for backwards compatibility
      
      * Apply suggestion from code review
      
      Co-authored-by: default avatarPierre Krieger <[email protected]>
      
      * Apply suggestions from code review
      
      Co-authored-by: default avatarAndré 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: default avatarPierre Krieger <[email protected]>
      Co-authored-by: default avatarAndré Silva <[email protected]>
      Co-authored-by: default avatarAndré Silva <[email protected]>
      0d6884b9
  27. Mar 11, 2021
  28. Feb 19, 2021
    • Bastian Köcher's avatar
      Ensure we spawn the block import worker as an essential task (#8155) · 821e018d
      Bastian Köcher authored
      * Ensure we spawn the block import worker as an essential task
      
      This pr ensures that we spawn the block import worker as an essential
      task. This is quite important as we need to bring down the node when the
      block import is done. Besides that it adds some debug output to the
      block import worker.
      
      * Don't be stupid :D
      821e018d
  29. Feb 04, 2021
  30. Jan 04, 2021
    • Bastian Köcher's avatar
      Happy new year (#7814) · e3e651f7
      Bastian Köcher authored
      * Happy new year
      
      Updates the copyright years and fixes wrong license headers.
      
      * Fix the template
      
      * Split HEADER into HEADER-APACHE & HEADER-GPL
      e3e651f7
  31. Nov 27, 2020
  32. Nov 23, 2020
  33. Oct 21, 2020
    • Cecile Tonglet's avatar
      Add node name to the log lines (#7328) · 8cebbd14
      Cecile Tonglet authored
      * Initial commit
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * Add notes to original source code
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * WIP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * Some doc
      
      * Test with trybuild
      
      * Revert "Test with trybuild" (issue with trybuild atm)
      
      This reverts commit 9055ec2206808ba3ddce6e3d87eb358907fa5e42.
      
      https://github.com/dtolnay/trybuild/issues/53
      
      * Apply suggestions
      
      * Rename derive to proc-macro
      
      * Remove "prefix" feature from informant
      
      * Blocking task should use SpawnHandle::spawn_blocking
      
      * Improve doc as suggested
      
      * Fixes
      
      Forked at: 601e2fa1
      
      
      Parent branch: origin/master
      
      * Apply suggestion
      
      * Update client/cli/proc-macro/src/lib.rs
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      
      * More suggestions
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * Improve error message
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * Fix async issue
      
      * CLEANUP
      
      Forked at: 601e2fa1
      Parent branch: origin/master
      
      * CLEANUP
      
      Forked at: 601e2fa1
      
      
      Parent branch: origin/master
      
      * Add test
      
      * fix doc test
      
      * Update client/cli/src/logging.rs
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      
      * Update client/basic-authorship/src/basic_authorship.rs
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      
      * Update client/basic-authorship/src/basic_authorship.rs
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      
      * Apply suggestions
      
      * Suggestions
      
      * Clarify doc
      
      * WIP
      
      Forked at: 601e2fa1
      
      
      Parent branch: origin/master
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      8cebbd14
  34. Sep 03, 2020
  35. Aug 07, 2020
  36. Jul 26, 2020
  37. Jul 09, 2020
  38. Jun 16, 2020
  39. Jun 08, 2020
    • Bastian Köcher's avatar
      Fix transaction pruning in tx-pool (#6276) · 663cd09b
      Bastian Köcher authored
      The `tree_route` generated by the import notification is only from the
      old best block to the new best parent. This means, it does not contain
      the new best block in `enacted()`. We need to prune the transactions of
      the new best block "manually" to fix this bug.
      
      Besides that, this pr also changed the `id` parameter of the `NewBlock`
      chain event to `hash`. The hash of a block is unique in contrast to the
      block number. (Block id can either be number or hash)
      663cd09b
  40. Jun 05, 2020