Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reinitialize should allow to override existing config in collationGeneration #4833

Merged
Merged
Show file tree
Hide file tree
Changes from 3 commits
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
6 changes: 1 addition & 5 deletions polkadot/node/collation-generation/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,7 @@ impl CollationGenerationSubsystem {
Ok(FromOrchestra::Communication {
msg: CollationGenerationMessage::Reinitialize(config),
}) => {
if self.config.is_none() {
gum::error!(target: LOG_TARGET, "no initial initialization");
} else {
self.config = Some(Arc::new(config));
}
self.config = Some(Arc::new(config));
false
},
Ok(FromOrchestra::Communication {
Expand Down
12 changes: 12 additions & 0 deletions prdoc/pr_4833.prdoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
title: "Reinitialize should allow to override existing config in collationGeneration"

doc:
- audience: Node Dev
description: |
The Reinitialize collationGeneration subsystem message currently fails if no other config is already set_block_length.
bkchr marked this conversation as resolved.
Show resolved Hide resolved
As it is difficult to query the collationGeneration subsystem to check when to call Initialize or Reinitialize, this PR
proposes that Reinitialize overrides the configuration regardless if there was one already set.

crates:
- name: polkadot-node-collation-generation
bump: none
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be patch as the behaviour changes.

bkchr marked this conversation as resolved.
Show resolved Hide resolved
Loading