Unverified Commit 11df6f86 authored by Sergey Pepyakin's avatar Sergey Pepyakin Committed by GitHub
Browse files

let go fees (#1867)

parent 6c2a7532
Pipeline #112406 canceled with stages
in 10 minutes and 48 seconds
...@@ -272,7 +272,6 @@ async fn handle_new_activations<Context: SubsystemContext>( ...@@ -272,7 +272,6 @@ async fn handle_new_activations<Context: SubsystemContext>(
}; };
let commitments = CandidateCommitments { let commitments = CandidateCommitments {
fees: collation.fees,
upward_messages: collation.upward_messages, upward_messages: collation.upward_messages,
new_validation_code: collation.new_validation_code, new_validation_code: collation.new_validation_code,
head_data: collation.head_data, head_data: collation.head_data,
...@@ -381,7 +380,6 @@ mod tests { ...@@ -381,7 +380,6 @@ mod tests {
fn test_collation() -> Collation { fn test_collation() -> Collation {
Collation { Collation {
fees: Default::default(),
upward_messages: Default::default(), upward_messages: Default::default(),
new_validation_code: Default::default(), new_validation_code: Default::default(),
head_data: Default::default(), head_data: Default::default(),
......
...@@ -677,7 +677,6 @@ impl CandidateBackingJob { ...@@ -677,7 +677,6 @@ impl CandidateBackingJob {
let erasure_root = branches.root(); let erasure_root = branches.root();
let commitments = CandidateCommitments { let commitments = CandidateCommitments {
fees: outputs.fees,
upward_messages: outputs.upward_messages, upward_messages: outputs.upward_messages,
erasure_root, erasure_root,
new_validation_code: outputs.new_validation_code, new_validation_code: outputs.new_validation_code,
...@@ -1160,7 +1159,6 @@ mod tests { ...@@ -1160,7 +1159,6 @@ mod tests {
ValidationResult::Valid(ValidationOutputs { ValidationResult::Valid(ValidationOutputs {
head_data: expected_head_data.clone(), head_data: expected_head_data.clone(),
upward_messages: Vec::new(), upward_messages: Vec::new(),
fees: Default::default(),
new_validation_code: None, new_validation_code: None,
processed_downward_messages: 0, processed_downward_messages: 0,
}, test_state.validation_data.persisted), }, test_state.validation_data.persisted),
...@@ -1280,7 +1278,6 @@ mod tests { ...@@ -1280,7 +1278,6 @@ mod tests {
ValidationResult::Valid(ValidationOutputs { ValidationResult::Valid(ValidationOutputs {
head_data: expected_head_data.clone(), head_data: expected_head_data.clone(),
upward_messages: Vec::new(), upward_messages: Vec::new(),
fees: Default::default(),
new_validation_code: None, new_validation_code: None,
processed_downward_messages: 0, processed_downward_messages: 0,
}, test_state.validation_data.persisted), }, test_state.validation_data.persisted),
...@@ -1419,7 +1416,6 @@ mod tests { ...@@ -1419,7 +1416,6 @@ mod tests {
ValidationResult::Valid(ValidationOutputs { ValidationResult::Valid(ValidationOutputs {
head_data: expected_head_data.clone(), head_data: expected_head_data.clone(),
upward_messages: Vec::new(), upward_messages: Vec::new(),
fees: Default::default(),
new_validation_code: None, new_validation_code: None,
processed_downward_messages: 0, processed_downward_messages: 0,
}, test_state.validation_data.persisted), }, test_state.validation_data.persisted),
...@@ -1575,7 +1571,6 @@ mod tests { ...@@ -1575,7 +1571,6 @@ mod tests {
ValidationResult::Valid(ValidationOutputs { ValidationResult::Valid(ValidationOutputs {
head_data: expected_head_data.clone(), head_data: expected_head_data.clone(),
upward_messages: Vec::new(), upward_messages: Vec::new(),
fees: Default::default(),
new_validation_code: None, new_validation_code: None,
processed_downward_messages: 0, processed_downward_messages: 0,
}, test_state.validation_data.persisted), }, test_state.validation_data.persisted),
......
...@@ -492,7 +492,6 @@ mod tests { ...@@ -492,7 +492,6 @@ mod tests {
ValidationOutputs { ValidationOutputs {
head_data: HeadData(head_data), head_data: HeadData(head_data),
upward_messages: Vec::new(), upward_messages: Vec::new(),
fees: 0,
new_validation_code: None, new_validation_code: None,
processed_downward_messages: 0, processed_downward_messages: 0,
}, },
......
...@@ -490,7 +490,6 @@ fn validate_candidate_exhaustive<B: ValidationBackend, S: SpawnNamed + 'static>( ...@@ -490,7 +490,6 @@ fn validate_candidate_exhaustive<B: ValidationBackend, S: SpawnNamed + 'static>(
let outputs = ValidationOutputs { let outputs = ValidationOutputs {
head_data: res.head_data, head_data: res.head_data,
upward_messages: res.upward_messages, upward_messages: res.upward_messages,
fees: 0,
new_validation_code: res.new_validation_code, new_validation_code: res.new_validation_code,
processed_downward_messages: res.processed_downward_messages, processed_downward_messages: res.processed_downward_messages,
}; };
...@@ -850,7 +849,6 @@ mod tests { ...@@ -850,7 +849,6 @@ mod tests {
assert_matches!(v, ValidationResult::Valid(outputs, used_validation_data) => { assert_matches!(v, ValidationResult::Valid(outputs, used_validation_data) => {
assert_eq!(outputs.head_data, HeadData(vec![1, 1, 1])); assert_eq!(outputs.head_data, HeadData(vec![1, 1, 1]));
assert_eq!(outputs.upward_messages, Vec::new()); assert_eq!(outputs.upward_messages, Vec::new());
assert_eq!(outputs.fees, 0);
assert_eq!(outputs.new_validation_code, Some(vec![2, 2, 2].into())); assert_eq!(outputs.new_validation_code, Some(vec![2, 2, 2].into()));
assert_eq!(used_validation_data, validation_data); assert_eq!(used_validation_data, validation_data);
}); });
......
...@@ -27,7 +27,7 @@ use parity_scale_codec::{Decode, Encode}; ...@@ -27,7 +27,7 @@ use parity_scale_codec::{Decode, Encode};
use polkadot_primitives::v1::{ use polkadot_primitives::v1::{
Hash, CommittedCandidateReceipt, CandidateReceipt, CompactStatement, Hash, CommittedCandidateReceipt, CandidateReceipt, CompactStatement,
EncodeAs, Signed, SigningContext, ValidatorIndex, ValidatorId, EncodeAs, Signed, SigningContext, ValidatorIndex, ValidatorId,
UpwardMessage, Balance, ValidationCode, PersistedValidationData, ValidationData, UpwardMessage, ValidationCode, PersistedValidationData, ValidationData,
HeadData, PoV, CollatorPair, Id as ParaId, ValidationOutputs, HeadData, PoV, CollatorPair, Id as ParaId, ValidationOutputs,
}; };
use polkadot_statement_table::{ use polkadot_statement_table::{
...@@ -253,8 +253,6 @@ impl std::convert::TryFrom<FromTableMisbehavior> for MisbehaviorReport { ...@@ -253,8 +253,6 @@ impl std::convert::TryFrom<FromTableMisbehavior> for MisbehaviorReport {
/// - contains a proof of validity. /// - contains a proof of validity.
#[derive(Clone, Encode, Decode)] #[derive(Clone, Encode, Decode)]
pub struct Collation { pub struct Collation {
/// Fees paid from the chain to the relay chain validators.
pub fees: Balance,
/// Messages destined to be interpreted by the Relay chain itself. /// Messages destined to be interpreted by the Relay chain itself.
pub upward_messages: Vec<UpwardMessage>, pub upward_messages: Vec<UpwardMessage>,
/// New validation code. /// New validation code.
......
...@@ -318,8 +318,6 @@ pub struct ValidationOutputs { ...@@ -318,8 +318,6 @@ pub struct ValidationOutputs {
pub head_data: HeadData, pub head_data: HeadData,
/// Upward messages to the relay chain. /// Upward messages to the relay chain.
pub upward_messages: Vec<UpwardMessage>, pub upward_messages: Vec<UpwardMessage>,
/// Fees paid to the validators of the relay-chain.
pub fees: Balance,
/// The new validation code submitted by the execution, if any. /// The new validation code submitted by the execution, if any.
pub new_validation_code: Option<ValidationCode>, pub new_validation_code: Option<ValidationCode>,
/// The number of messages processed from the DMQ. /// The number of messages processed from the DMQ.
...@@ -330,8 +328,6 @@ pub struct ValidationOutputs { ...@@ -330,8 +328,6 @@ pub struct ValidationOutputs {
#[derive(PartialEq, Eq, Clone, Encode, Decode)] #[derive(PartialEq, Eq, Clone, Encode, Decode)]
#[cfg_attr(feature = "std", derive(Debug, Default, Hash))] #[cfg_attr(feature = "std", derive(Debug, Default, Hash))]
pub struct CandidateCommitments { pub struct CandidateCommitments {
/// Fees paid from the chain to the relay chain validators.
pub fees: Balance,
/// Messages destined to be interpreted by the Relay chain itself. /// Messages destined to be interpreted by the Relay chain itself.
pub upward_messages: Vec<UpwardMessage>, pub upward_messages: Vec<UpwardMessage>,
/// The root of a block's erasure encoding Merkle tree. /// The root of a block's erasure encoding Merkle tree.
......
...@@ -22,8 +22,6 @@ The process of generating a collation for a parachain is very parachain-specific ...@@ -22,8 +22,6 @@ The process of generating a collation for a parachain is very parachain-specific
```rust ```rust
pub struct Collation { pub struct Collation {
/// Fees paid from the chain to the relay chain validators.
pub fees: Balance,
/// Messages destined to be interpreted by the Relay chain itself. /// Messages destined to be interpreted by the Relay chain itself.
pub upward_messages: Vec<UpwardMessage>, pub upward_messages: Vec<UpwardMessage>,
/// New validation code. /// New validation code.
......
...@@ -247,8 +247,6 @@ The execution and validation of parachain or parathread candidates produces a nu ...@@ -247,8 +247,6 @@ The execution and validation of parachain or parathread candidates produces a nu
#[derive(PartialEq, Eq, Clone, Encode, Decode)] #[derive(PartialEq, Eq, Clone, Encode, Decode)]
#[cfg_attr(feature = "std", derive(Debug, Default))] #[cfg_attr(feature = "std", derive(Debug, Default))]
struct CandidateCommitments { struct CandidateCommitments {
/// Fees paid from the chain to the relay chain validators.
fees: Balance,
/// Messages directed to other paras routed via the relay chain. /// Messages directed to other paras routed via the relay chain.
horizontal_messages: Vec<OutboundHrmpMessage>, horizontal_messages: Vec<OutboundHrmpMessage>,
/// Messages destined to be interpreted by the Relay chain itself. /// Messages destined to be interpreted by the Relay chain itself.
...@@ -293,8 +291,6 @@ struct ValidationOutputs { ...@@ -293,8 +291,6 @@ struct ValidationOutputs {
horizontal_messages: Vec<OutboundHrmpMessage>, horizontal_messages: Vec<OutboundHrmpMessage>,
/// Upwards messages to the relay chain. /// Upwards messages to the relay chain.
upwards_messages: Vec<UpwardsMessage>, upwards_messages: Vec<UpwardsMessage>,
/// Fees paid to the validators of the relay-chain.
fees: Balance,
/// The new validation code submitted by the execution, if any. /// The new validation code submitted by the execution, if any.
new_validation_code: Option<ValidationCode>, new_validation_code: Option<ValidationCode>,
/// The number of messages processed from the DMQ. /// The number of messages processed from the DMQ.
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment