Skip to content
  1. Apr 01, 2021
    • asynchronous rob's avatar
      Approval Voting improvements (#2781) · 57b56770
      asynchronous rob authored
      
      
      * extract database from av-store itself
      
      * generalize approval-voting over database type
      
      * modes (without handling) and pruning old wakeups
      
      * rework approval importing
      
      * add our_approval_sig to ApprovalEntry
      
      * import assignment
      
      * guide updates for check-full-approval changes
      
      * some aux functions
      
      * send messages when becoming active.
      
      * guide: network bridge sends view updates only when done syncing
      
      * network bridge: send view updates only when done syncing
      
      * tests for new network-bridge behavior
      
      * add a test for updating approval entry with sig
      
      * fix some warnings
      
      * test load-all-blocks
      
      * instantiate new parachains DB
      
      * fix network-bridge empty view updates
      
      * tweak
      
      * fix wasm build, i think
      
      * Update node/core/approval-voting/src/lib.rs
      
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      
      * add some versioning to parachains_db
      
      * warnings
      
      * fix merge changes
      
      * remove versioning again
      
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      57b56770
  2. Mar 30, 2021
  3. Mar 29, 2021
  4. Mar 28, 2021
    • asynchronous rob's avatar
      Split NetworkBridge and break cycles with Unbounded (#2736) · 8ebbe19d
      asynchronous rob authored
      
      
      * overseer: pass messages directly between subsystems
      
      * test that message is held on to
      
      * Update node/overseer/src/lib.rs
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      
      * give every subsystem an unbounded sender too
      
      * remove metered_channel::name
      
      1. we don't provide good names
      2. these names are never used anywhere
      
      * unused mut
      
      * remove unnecessary &mut
      
      * subsystem unbounded_send
      
      * remove unused MaybeTimer
      
      We have channel size metrics that serve the same purpose better now and the implementation of message timing was pretty ugly.
      
      * remove comment
      
      * split up senders and receivers
      
      * update metrics
      
      * fix tests
      
      * fix test subsystem context
      
      * use SubsystemSender in jobs system now
      
      * refactor of awful jobs code
      
      * expose public `run` on JobSubsystem
      
      * update candidate backing to new jobs & use unbounded
      
      * bitfield signing
      
      * candidate-selection
      
      * provisioner
      
      * approval voting: send unbounded for assignment/approvals
      
      * async not needed
      
      * begin bridge split
      
      * split up network tasks into background worker
      
      * port over network bridge
      
      * Update node/network/bridge/src/lib.rs
      
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      
      * rename ValidationWorkerNotifications
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      8ebbe19d
    • ordian's avatar
      approval-voting: more spans and metrics (#2742) · 171fc699
      ordian authored
      * approval-voting: more spans and metrics
      
      * s/db/approval db
      171fc699
    • asynchronous rob's avatar
      Approval voting failsafe (#2675) · ef816b08
      asynchronous rob authored
      
      
      * add consensus log type
      
      * origin and issue force_approve
      
      * add origin in runtimes
      
      * ref API
      
      * scrape force_approve digest from header
      
      * add parent_hash to BlockEntry
      
      * add block_number to block entry and force_approve skeleton
      
      * implement and plug in force-approve
      
      * test force_approve
      
      * test force_approve extraction
      
      * westend runtime
      
      * Update node/core/approval-voting/src/approval_db/v1/mod.rs
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      
      * rename
      
      * Update runtime/parachains/src/initializer.rs
      
      Co-authored-by: default avatarAndré Silva <[email protected]>
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      Co-authored-by: default avatarAndré Silva <[email protected]>
      ef816b08
  5. Mar 26, 2021
  6. Mar 25, 2021
  7. Mar 24, 2021
  8. Mar 23, 2021
  9. Mar 19, 2021
  10. Mar 17, 2021
  11. Mar 12, 2021
  12. Mar 11, 2021
  13. Mar 10, 2021
    • asynchronous rob's avatar
      Better error handling in approval-voting (#2603) · 40a584be
      asynchronous rob authored
      * make approval voting resilient to dropped requests
      
      * some more
      
      * skip whole chain if encountering spurious error
      40a584be
    • ordian's avatar
      prefix parachain log targets with parachain:: (#2600) · baa691de
      ordian authored
      * prefix parachain log targets with parachain::
      
      * even more consistent
      baa691de
    • Ashley's avatar
      Companion PR for substrate PR 8072 - Add a config field to babe epochs (#2467) · 956be35d
      Ashley authored
      * Add a config field to babe epochs
      
      * Fix test
      
      * Add BABE_GENESIS_EPOCH_CONFIG consts
      
      * Use PrimaryAndSecondaryVRFSlots and remove newlines
      
      * Make epoch_configs Some
      
      * Fix tests
      
      * Fix test service tests
      
      * Add a BabeEpochConfigMigrations OnRuntimeUpgrade
      
      * Apply suggestions
      
      * Use PrimaryAndSecondaryPlainSlots in kusama
      
      * Remove migration from test runtime and rococo
      
      * Add HasPalletPrefix
      
      * Rename to BabePalletPrefix and change BabeApi -> Babe
      
      * "Update Substrate"
      
      * Update substrate
      
      * Resolve parantheses errors
      
      Co-authored-by: parity-processbot <>
      956be35d
  14. Mar 09, 2021
  15. Feb 26, 2021
    • Robert Klotzner's avatar
      Request based availability distribution (#2423) · 48409e55
      Robert Klotzner authored
      * WIP
      
      * availability distribution, still very wip.
      
      Work on the requesting side of things.
      
      * Some docs on what I intend to do.
      
      * Checkpoint of session cache implementation
      
      as I will likely replace it with something smarter.
      
      * More work, mostly on cache
      
      and getting things to type check.
      
      * Only derive MallocSizeOf and Debug for std.
      
      * availability-distribution: Cache feature complete.
      
      * Sketch out logic in `FetchTask` for actual fetching.
      
      - Compile fixes.
      - Cleanup.
      
      * Format cleanup.
      
      * More format fixes.
      
      * Almost feature complete `fetch_task`.
      
      Missing:
      
      - Check for cancel
      - Actual querying of peer ids.
      
      * Finish FetchTask so far.
      
      * Directly use AuthorityDiscoveryId in protocol and cache.
      
      * Resolve `AuthorityDiscoveryId` on sending requests.
      
      * Rework fetch_task
      
      - also make it impossible to check the wrong chunk index.
      - Export needed function in validator_discovery.
      
      * From<u32> implementation for `ValidatorIndex`.
      
      * Fixes and more integration work.
      
      * Make session cache proper lru cache.
      
      * Use proper lru cache.
      
      * Requester finished.
      
      * ProtocolState -> Requester
      
      Also make sure to not fetch our own chunk.
      
      * Cleanup + fixes.
      
      * Remove unused functions
      
      - FetchTask::is_finished
      - SessionCache::fetch_session_info
      
      * availability-distribution responding side.
      
      * Cleanup + Fixes.
      
      * More fixes.
      
      * More fixes.
      
      adder-collator is running!
      
      * Some docs.
      
      * Docs.
      
      * Fix reporting of bad guys.
      
      * Fix tests
      
      * Make all tests compile.
      
      * Fix test.
      
      * Cleanup + get rid of some warnings.
      
      * state -> requester
      
      * Mostly doc fixes.
      
      * Fix test suite.
      
      * Get rid of now redundant message types.
      
      * WIP
      
      * Rob's review remarks.
      
      * Fix test suite.
      
      * core.relay_parent -> leaf for session request.
      
      * Style fix.
      
      * Decrease request timeout.
      
      * Cleanup obsolete errors.
      
      * Metrics + don't fail on non fatal errors.
      
      * requester.rs -> requester/mod.rs
      
      * Panic on invalid BadValidator report.
      
      * Fix indentation.
      
      * Use typed default timeout constant.
      
      * Make channel size 0, as each sender gets one slot anyways.
      
      * Fix incorrect metrics initialization.
      
      * Fix build after merge.
      
      * More fixes.
      
      * Hopefully valid metrics names.
      
      * Better metrics names.
      
      * Some tests that already work.
      
      * Slightly better docs.
      
      * Some more tests.
      
      * Fix network bridge test.
      48409e55
  16. Feb 25, 2021
  17. Feb 23, 2021
    • asynchronous rob's avatar
      Approval Checking Improvements Omnibus (#2480) · 3300b533
      asynchronous rob authored
      * add tracing to approval voting
      
      * notify if session info is not working
      
      * add dispute period to chain specs
      
      * propagate genesis session to parachains runtime
      
      * use `on_genesis_session`
      
      * protect against zero cores in computation
      
      * tweak voting rule to be based off of best and add logs
      
      * genesis configuration should use VRF slots only
      
      * swallow more keystore errors
      
      * add some docs
      
      * make validation-worker args non-optional and update clap
      
      * better tracing for bitfield signing and provisioner
      
      * pass amount of bits in bitfields to inclusion instead of recomputing
      
      * debug -> warn for some logs
      
      * better tracing for availability recovery
      
      * a little av-store tracing
      
      * bridge: forward availability recovery messages
      
      * add missing try_from impl
      
      * some more tracing
      
      * improve approval distribution tracing
      
      * guide: hold onto pending approval messages until NewBlocks
      
      * Hold onto pending approval messages until NewBlocks
      
      * guide: adjust comment
      
      * process all actions for one wakeup at a time
      
      * vec
      
      * fix network bridge test
      
      * replace randomness-collective-flip with Babe
      
      * remove PairNotFound
      3300b533
  18. Feb 22, 2021
  19. Feb 18, 2021
  20. Feb 17, 2021
  21. Feb 16, 2021
    • ordian's avatar
      fix approval import tests and some bugs (#2452) · b28e1b4e
      ordian authored
      * tests: use future::join
      
      * fix panic in cache_session_info_for_head
      
      * fix test assertion
      
      * fix infinite loop in determine_new_blocks
      
      * fix ordering in determine_new_blocks
      
      * fix expected ancestry in tests
      b28e1b4e
    • asynchronous rob's avatar
      Integrate Approval Voting into Overseer / Service / GRANDPA (#2412) · 4f21cc7e
      asynchronous rob authored
      * integrate approval voting into overseer
      
      * expose public API and make keystore arc
      
      * integrate overseer in service
      
      * guide: `ApprovedAncestor` returns block number
      
      * return block number along with hash from ApprovedAncestor
      
      * introduce a voting rule for reporting on approval checking
      
      * integrate the delay voting rule
      
      * Rococo configuration
      
      * fix compilation and add slack
      
      * fix web-wasm build
      
      * tweak parameterization
      
      * migrate voting rules to asycn
      
      * remove hack comment
      4f21cc7e
  22. Feb 11, 2021
    • asynchronous rob's avatar
      Implement Approval Voting Subsystem (#2112) · e48c6875
      asynchronous rob authored
      
      
      * skeleton
      
      * skeleton aux-schema module
      
      * start approval types
      
      * start aux schema with aux store
      
      * doc
      
      * finish basic types
      
      * start approval types
      
      * doc
      
      * finish basic types
      
      * write out schema types
      
      * add debug and codec impls to approval types
      
      * add debug and codec impls to approval types
      
      also add some key computation
      
      * add debug and codec impls to approval types
      
      * getters for block and candidate entries
      
      * grumbles
      
      * remove unused AssignmentId
      
      * load_decode utility
      
      * implement DB clearing
      
      * function for adding new block entry to aux store
      
      * start `canonicalize` implementation
      
      * more skeleton
      
      * finish implementing canonicalize
      
      * tag TODO
      
      * implement a test AuxStore
      
      * add allow(unused)
      
      * basic loading and deleting test
      
      * block_entry test function
      
      * add a test for `add_block_entry`
      
      * ensure range is exclusive at end
      
      * test clear()
      
      * test that add_block sets children
      
      * add a test for canonicalize
      
      * extract Pre-digest from header
      
      * utilities for extracting RelayVRFStory from the header-chain
      
      * add approval voting message types
      
      * approval distribution message type
      
      * subsystem skeleton
      
      * state struct
      
      * add futures-timer
      
      * prepare service for babe slot duration
      
      * more skeleton
      
      * better integrate AuxStore
      
      * RelayVRF -> RelayVRFStory
      
      * canonicalize
      
      * implement some tick functionality
      
      * guide: tweaks
      
      * check_approval
      
      * more tweaks and helpers
      
      * guide: add core index to candidate event
      
      * primitives: add core index to candidate event
      
      * runtime: add core index to candidate events
      
      * head handling (session window)
      
      * implement `determine_new_blocks`
      
      * add TODO
      
      * change error type on functions
      
      * compute RelayVRFModulo assignments
      
      * compute RelayVRFDelay assignments
      
      * fix delay tranche calc
      
      * assignment checking
      
      * pluralize
      
      * some dummy code for fetching assignments
      
      * guide: add babe epoch runtime API
      
      * implement a current_epoch() runtime API
      
      * compute assignments
      
      * candidate events get backing group
      
      * import blocks and assignments into DB
      
      * push block approval meta
      
      * add message types, no overseer integration yet
      
      * notify approval distribution of new blocks
      
      * refactor import into separate functions
      
      * impl tranches_to_approve
      
      * guide: improve function signatures
      
      * guide: remove Tick from ApprovalEntry
      
      * trigger and broadcast assignment
      
      * most of approval launching
      
      * remove byteorder crate
      
      * load blocks back to finality, except on startup
      
      * check unchecked assignments
      
      * add claimed core to approval voting message
      
      * fix checks
      
      * assign only to backing group
      
      * remove import_checked_assignment from guide
      
      * newline
      
      * import assignments
      
      * abstract out a bit
      
      * check and import approvals
      
      * check full approvals from assignment import too
      
      * comment
      
      * create a Transaction utility
      
      * must_use
      
      * use transaction in `check_full_approvals`
      
      * wire up wakeups
      
      * add Ord to CandidateHash
      
      * wakeup refactoring
      
      * return candidate info from add_block_entry
      
      * schedule wakeups
      
      * background task: do candidate validation
      
      * forward candidate validation requests
      
      * issue approval votes when requested
      
      * clean up a couple TODOs
      
      * fix up session caching
      
      * clean up last unimplemented!() items
      
      * fix remaining warnings
      
      * remove TODO
      
      * implement handle_approved_ancestor
      
      * update Cargo.lock
      
      * fix runtime API tests
      
      * guide: cleanup assignment checking
      
      * use claimed candidate index instead of core
      
      * extract time to a trait
      
      * tests module
      
      * write a mock clock for testing
      
      * allow swapping out the clock
      
      * make abstract over assignment criteria
      
      * add some skeleton tests and simplify params
      
      * fix backing group check
      
      * do backing group check inside check_assignment_cert
      
      * write some empty test functions to implement
      
      * add a test for non-backing
      
      * test that produced checks pass
      
      * some empty test ideas
      
      * runtime/inclusion: remove outdated TODO
      
      * fix compilation
      
      * av-store: fix tests
      
      * dummy cert
      
      * criteria tests
      
      * move `TestStore` to main tests file
      
      * fix unused warning
      
      * test harness beginnings
      
      * resolve slots renaming fallout
      
      * more compilation fixes
      
      * wip: extract pure data into a separate module
      
      * wip: extract pure data into a separate module
      
      * move types completely to v1
      
      * add persisted_entries
      
      * add conversion trait impls
      
      * clean up some warnings
      
      * extract import logic to own module
      
      * schedule wakeups
      
      * experiment with Actions
      
      * uncomment approval-checking
      
      * separate module for approval checking utilities
      
      * port more code to use actions
      
      * get approval pipeline using actions
      
      * all logic is uncommented
      
      * main loop processes actions
      
      * all loop logic uncommented
      
      * separate function for handling actions
      
      * remove last unimplemented item
      
      * clean up warnings
      
      * State gives read-only access to underlying DB
      
      * tests for approval checking
      
      * tests for approval criteria
      
      * skeleton test module for import
      
      * list of import tests to do
      
      * some test glue code
      
      * test reject bad assignment
      
      * test slot too far in future
      
      * test reject assignment with unknown candidate
      
      * remove loads_blocks tests
      
      * determine_new_blocks back to finalized & harness
      
      * more coverage for determining new blocks
      
      * make `imported_block_info` have less reliance on State
      
      * candidate_info tests
      
      * tests for session caching
      
      * remove println
      
      * extricate DB and main TestStores
      
      * rewrite approval checking logic to counteract early delays
      
      * move state out of function
      
      * update approval-checking tests
      
      * tweak wakeups & scheduling logic
      
      * rename check_full_approvals
      
      * test that assignment import updates candidate
      
      * some approval import tests
      
      * some tests for check_and_apply_approval
      
      * add 'full' qualifier to avoid confusion
      
      * extract should-trigger logic to separate function
      
      * some tests for all triggering
      
      * tests for when we trigger assignments
      
      * test wakeups
      
      * add block utilities for testing
      
      * some more tests for approval updates
      
      * approved_ancestor tests
      
      * new action type for launch approval
      
      * process-wakeup tests
      
      * clean up some warnings
      
      * fix in_future test
      
      * approval checking tests
      
      * tighten up too-far-in-future
      
      * special-case genesis when caching sessions
      
      * fix bitfield len
      
      Co-authored-by: default avatarAndronik Ordian <[email protected]>
      e48c6875
  23. Jan 29, 2021
  24. Jan 28, 2021
  25. Jan 18, 2021
    • asynchronous rob's avatar
      Approval Voting Database (#2162) · b009cbe8
      asynchronous rob authored
      
      
      * skeleton
      
      * skeleton aux-schema module
      
      * start approval types
      
      * start aux schema with aux store
      
      * doc
      
      * finish basic types
      
      * start approval types
      
      * doc
      
      * finish basic types
      
      * write out schema types
      
      * add debug and codec impls to approval types
      
      * add debug and codec impls to approval types
      
      also add some key computation
      
      * add debug and codec impls to approval types
      
      * getters for block and candidate entries
      
      * grumbles
      
      * remove unused AssignmentId
      
      * load_decode utility
      
      * implement DB clearing
      
      * function for adding new block entry to aux store
      
      * start `canonicalize` implementation
      
      * more skeleton
      
      * finish implementing canonicalize
      
      * tag TODO
      
      * implement a test AuxStore
      
      * add allow(unused)
      
      * basic loading and deleting test
      
      * block_entry test function
      
      * add a test for `add_block_entry`
      
      * ensure range is exclusive at end
      
      * test clear()
      
      * test that add_block sets children
      
      * add a test for canonicalize
      
      * Update node/core/approval-voting/src/aux_schema/mod.rs
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      
      * Update node/core/approval-voting/src/aux_schema/tests.rs
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      
      * Update node/core/approval-voting/src/aux_schema/mod.rs
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      b009cbe8