Skip to content
  1. Jun 17, 2021
    • Lldenaurois's avatar
      Extract and test count_no_shows method for approval voting (#3264) · f8ed46f4
      Lldenaurois authored
      * node/approval-voting: extract and test count_no_shows method
      
      This commit extracts no_show computation into a pure function so that it can be
      extensively unit tested.
      
      * node/approval-voting: ignore invalid validator indexes in count_no_show
      
      Previously indexes that were past the length of the approvals bitvector
      would contribute to the no_show count or the next_no_show value. This
      commit changes the behavior to ignore garbage values.
      
      * node/approval-voting: add comment for next_no_show adding clock_drift
      f8ed46f4
    • ordian's avatar
      cleanup more tests and spaces (#3288) · 325cc888
      ordian authored
      * cleanup more tests and spaces
      
      * oops
      325cc888
  2. Jun 16, 2021
    • asynchronous rob's avatar
      extract determine_new_blocks into a separate utility (#3261) · 462ca043
      asynchronous rob authored
      * extract determine_new_blocks into a separate utility
      
      * rework docs
      462ca043
    • Lldenaurois's avatar
      Approval checking unit tests (#3252) · 0da70dfa
      Lldenaurois authored
      * node/approval_checking: break out filled_tranch_iterator method
      
      In the subsequent commit, we will begin to test this method in
      isolation.
      
      * node/approval-voting: fix tranche back-filling algorithm
      
      Previously, this algorithm would generate duplicate, empty entries for
      tranches (1..pre_end). This is caused because the initial value (0) for
      gap_end is treated as the end of a prior tranche that wasn't actually
      processed. The first pass thus would add (1..tranche) empty entries, in
      addition to the (0..pre_end) empty entries chained at the end of the
      method.
      
      This is fixed by using the current tranche as the gap_start for the
      first iteration, ensuring that the approval_entries_filled only produces
      entries in the range (pre_end..post_start).
      
      * Address feedback
      0da70dfa
    • Bernhard Schuster's avatar
      malus - mockable overseer mvp (#3224) · 44a8aa23
      Bernhard Schuster authored
      44a8aa23
  3. Jun 15, 2021
  4. Jun 14, 2021
  5. Jun 13, 2021
    • ordian's avatar
      approval votes checking logs (#3233) · 93e42fb2
      ordian authored
      * approval-voting: logs for invalid votes
      
      * proper errors for assignment checks
      
      * proper errors for approval checks
      93e42fb2
    • asynchronous rob's avatar
    • asynchronous rob's avatar
      Dispute Coordinator Subsystem (#3150) · 5bc2b277
      asynchronous rob authored
      
      
      * skeleton for dispute-coordinator
      
      * add coordinator and participation message types
      
      * begin dispute-coordinator DB
      
      * functions for loading
      
      * implement strongly-typed DB transaction
      
      * add some tests for DB transaction
      
      * core logic for pruning
      
      * guide: update candidate-votes key for coordinator
      
      * update candidate-votes key
      
      * use big-endian encoding for session, and implement upper bound generator
      
      * finish implementing pruning
      
      * add a test for note_current_session
      
      * define state of the subsystem itself
      
      * barebones subsystem definition
      
      * control flow
      
      * more control flow
      
      * implement session-updating logic
      
      * trace
      
      * control flow for message handling
      
      * Update node/core/dispute-coordinator/src/lib.rs
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      
      * Update node/subsystem/src/messages.rs
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      
      * some more control flow
      
      * guide: remove overlay
      
      * more control flow
      
      * implement some DB getters
      
      * make progress on importing statements
      
      * add SignedDisputeStatement struct
      
      * move ApprovalVote to shared primitives
      
      * add a signing-payload API to explicit dispute statements
      
      * add signing-payload to CompactStatement
      
      * add relay-parent hash to seconded/valid dispute variatns
      
      * correct import
      
      * type-safe wrapper around dispute statements
      
      * use checked dispute statement in message type
      
      * extract rolling session window cache to subsystem-util
      
      * extract session window tests
      
      * approval-voting: use rolling session info cache
      
      * reduce dispute window to match runtime in practice
      
      * add byzantine_threshold and supermajority_threshold utilities to primitives
      
      * integrate rolling session window
      
      * Add PartialOrd to CandidateHash
      
      * add Ord to CandidateHash
      
      * implement active dispute update
      
      * add dispute messages to AllMessages
      
      * add dispute stubs to overseer
      
      * inform dispute participation to participate
      
      * implement issue_local_statement
      
      * implement `determine_undisputed_chain`
      
      * fix warnings
      
      * test harness for dispute coordinator tests
      
      * add more helpers to test harness
      
      * add some more helpers
      
      * some tests for dispute coordinator
      
      * ignore wrong validator indices
      
      * test finality voting rule constraint
      
      * add more tests
      
      * add variants to network bridge
      
      * fix test compilation
      
      * remove most dispute coordinator functionality
      
      as of #3222 we can do most of the work within the approval voting subsystem
      
      * Revert "remove most dispute coordinator functionality"
      
      This reverts commit 9cd615e8eb6ca0b382cbaff525d813e753d6004e.
      
      * Use thiserror
      
      Co-authored-by: default avatarBernhard Schuster <[email protected]>
      
      * Update node/core/dispute-coordinator/src/lib.rs
      
      Co-authored-by: default avatarBernhard Schuster <[email protected]>
      
      * extract tests to separate module
      
      * address nit
      
      * adjust run_iteration API
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      Co-authored-by: default avatarBernhard Schuster <[email protected]>
      5bc2b277
  6. Jun 12, 2021
  7. Jun 11, 2021
  8. Jun 09, 2021
  9. Jun 08, 2021
    • Lldenaurois's avatar
      Remove candidate selection (#3148) · 2abaca3a
      Lldenaurois authored
      * Create validator_side module
      
      * Subsume Candidate Selection
      
      * Add test to ensure candidate backing logic is correct
      
      * Ensure secondings are adequately cleaned up and address test flakyness
      
      * Address Feedback
      2abaca3a
  10. Jun 04, 2021
  11. Jun 01, 2021
  12. May 31, 2021
    • asynchronous rob's avatar
      Reversion Safety tools for overseer and subsystems (#3104) · 963993d2
      asynchronous rob authored
      * guide: reversion safety
      
      * guide: manage reversion safety in subsystems
      
      * add leaf status to ActivatedLeaf
      
      * add an LRU-cache to overseer for staleness detection
      
      * update ActivatedLeaf usages in tests to contain status field
      
      * add variant where missed accidentally
      
      * add some helpers to LeafStatus
      
      * address grumbles
      963993d2
  13. May 27, 2021
  14. May 24, 2021
  15. May 22, 2021
  16. May 21, 2021
  17. May 19, 2021
  18. May 15, 2021
  19. May 13, 2021
  20. May 03, 2021
    • Robert Klotzner's avatar
      More secure `Signed` implementation (#2963) · 0dbdfef9
      Robert Klotzner authored
      * Remove signature verification in backing.
      
      `SignedFullStatement` now signals that the signature has already been
      checked.
      
      * Remove unused check_payload function.
      
      * Introduced unchecked signed variants.
      
      * Fix inclusion to use unchecked variant.
      
      * More unchecked variants.
      
      * Use unchecked variants in protocols.
      
      * Start fixing statement-distribution.
      
      * Fixup statement distribution.
      
      * Fix inclusion.
      
      * Fix warning.
      
      * Fix backing properly.
      
      * Fix bitfield distribution.
      
      * Make crypto store optional for `RuntimeInfo`.
      
      * Factor out utility functions.
      
      * get_group_rotation_info
      
      * WIP: Collator cleanup + check signatures.
      
      * Convenience signature checking functions.
      
      * Check signature on collator-side.
      
      * Fix warnings.
      
      * Fix collator side tests.
      
      * Get rid of warnings.
      
      * Better Signed/UncheckedSigned implementation.
      
      Also get rid of Encode/Decode for Signed! *party*
      
      * Get rid of dead code.
      
      * Move Signed in its own module.
      
      * into_checked -> try_into_checked
      
      * Fix merge.
      0dbdfef9
    • Bastian Köcher's avatar
      Companion for Substrate#8526 (#2845) · 7830bae5
      Bastian Köcher authored
      * Update branch
      
      * Make it compile
      
      * Compile
      
      * gate approval-checking logic (#2470)
      
      * Fix build
      
      * Updates
      
      * Fix merge
      
      * Adds missing crate
      
      * Companion for Substrate#8386
      
      https://github.com/paritytech/substrate/pull/8386
      
      
      
      * Fix fix fix
      
      * Fix
      
      * Fix compilation
      
      * Rewrite to `ParachainsInherentDataProvider`
      
      * Make it compile
      
      * Renamings
      
      * Revert stuff
      
      * Remove stale file
      
      * Guide updates
      
      * Update node/core/parachains-inherent/src/lib.rs
      
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      
      * Update node/core/parachains-inherent/src/lib.rs
      
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      
      * Apply suggestions from code review
      
      * Reset accidental changes
      
      * More
      
      * Remove stale file
      
      * update Substrate
      
      Co-authored-by: default avatarRobert Habermeier <[email protected]>
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      Co-authored-by: parity-processbot <>
      7830bae5
  21. Apr 25, 2021
  22. Apr 16, 2021
    • Robert Klotzner's avatar
      Infrastructure improvements (#2897) · dacde443
      Robert Klotzner authored
      * Factor out runtime module into utils.
      
      * Add maybe_authority information to `PeerConnected` event.
      
      We already gather this information in authority discovery, so we might
      as well share it with others.
      
      This opens up an easy path to trigger validators differently from normal
      nodes, e.g. for prioritization. This change has become more important
      now, that we just connect to all validators and therefore just have a
      long peer list without any information about those nodes.
      
      * Test fix.
      dacde443
  23. Apr 14, 2021
  24. Apr 09, 2021
    • Robert Klotzner's avatar
      Req/res optimization for statement distribution (#2803) · 305375e1
      Robert Klotzner authored
      * Wip
      
      * Increase proposer timeout.
      
      * WIP.
      
      * Better timeout values now that we are going to be connected to all nodes. (#2778)
      
      * Better timeout values.
      
      * Fix typo.
      
      * Fix validator bandwidth.
      
      * Fix compilation.
      
      * Better and more consistent sizes.
      
      Most importantly code size is now 5 Meg, which is the limit we currently
      want to support in statement distribution.
      
      * Introduce statement fetching request.
      
      * WIP
      
      * Statement cache retrieval logic.
      
      * Review remarks by @rphmeier
      
      * Fixes.
      
      * Better requester logic.
      
      * WIP: Handle requester messages.
      
      * Missing dep.
      
      * Fix request launching logic.
      
      * Finish fetching logic.
      
      * Sending logic.
      
      * Redo code size calculations.
      
      Now that max code size is compressed size.
      
      * Update Cargo.lock (new dep)
      
      * Get request receiver to statement distribution.
      
      * Expose new functionality for responding to requests.
      
      * Cleanup.
      
      * Responder logic.
      
      * Fixes + Cleanup.
      
      * Cargo.lock
      
      * Whitespace.
      
      * Add lost copyright.
      
      * Launch responder task.
      
      * Typo.
      
      * info -> warn
      
      * Typo.
      
      * Fix.
      
      * Fix.
      
      * Update comment.
      
      * Doc fix.
      
      * Better large statement heuristics.
      
      * Fix tests.
      
      * Fix network bridge tests.
      
      * Add test for size estimate.
      
      * Very simple tests that checks we get LargeStatement.
      
      * Basic check, that fetching of large candidates is performed.
      
      * More tests.
      
      * Basic metrics for responder.
      
      * More metrics.
      
      * Use Encode::encoded_size().
      
      * Some useful spans.
      
      * Get rid of redundant metrics.
      
      * Don't add peer on duplicate.
      
      * Properly check hash
      
      instead of relying on signatures alone.
      
      * Preserve ordering + better flood protection.
      
      * Get rid of redundant clone.
      
      * Don't shutdown responder on failed query.
      
      And add test for this.
      
      * Smaller fixes.
      
      * Quotes.
      
      * Better queue size calculation.
      
      * A bit saner response sizes.
      
      * Fixes.
      305375e1
    • asynchronous rob's avatar
      set groups correctly even if not validator (#2863) · bc7761a3
      asynchronous rob authored
      shows what I get for being hasty last time. i added a test this time, which would have caught this issue last time.
      bc7761a3
  25. Apr 08, 2021