Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use AttestedCandidate as BackedCandidate
  • Loading branch information
montekki committed Jun 16, 2020
commit 270a373d3fa37337e4c7dcff2a7d4506902d983a
4 changes: 2 additions & 2 deletions node/messages/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ use futures::channel::{mpsc, oneshot};

use polkadot_primitives::{Hash, Signature};
use polkadot_primitives::parachain::{
AbridgedCandidateReceipt, PoVBlock, ErasureChunk,
AbridgedCandidateReceipt, PoVBlock, ErasureChunk, AttestedCandidate as BackedCandidate,
};
use polkadot_node_primitives::{
BackedCandidate, MisbehaviorReport, SignedStatement, SignedAvailabilityBitfield,
MisbehaviorReport, SignedStatement, SignedAvailabilityBitfield,
};

/// Signals sent by an overseer to a subsystem.
Expand Down
17 changes: 1 addition & 16 deletions node/primitives/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ use runtime_primitives::traits::AppVerify;
use polkadot_primitives::Hash;
use polkadot_primitives::parachain::{
AbridgedCandidateReceipt, CandidateReceipt, SigningContext, ValidatorSignature,
ValidatorIndex, ValidatorId, ValidityAttestation,
ValidatorIndex, ValidatorId,
};
use parity_scale_codec::{Encode, Decode};

Expand Down Expand Up @@ -141,18 +141,3 @@ impl SignedAvailabilityBitfield {

/// A bitfield signed by a particular validator about the availability of pending candidates.
pub struct Bitfields(pub Vec<SignedAvailabilityBitfield>);

/// A `CandidateReceipt` along with all data necessary to prove its backing.
///
/// This is submitted to the relay-chain to process and move along the candidate
/// to the pending-availability stage.
#[derive(Debug)]
pub struct BackedCandidate {
/// Candidate receipt.
pub candidate: AbridgedCandidateReceipt,
/// Votes for it
pub validity_votes: Vec<ValidityAttestation>,
/// The indices of validators who signed the candidate within the group. There is no need to include
/// bit for any validators who are not in the group, so this is more compact.
pub validator_indices: BitVec<bitvec::order::Lsb0, u8>,
}