diff --git a/collator/src/collator/mod.rs b/collator/src/collator/mod.rs index 98451a997..4be63b55f 100644 --- a/collator/src/collator/mod.rs +++ b/collator/src/collator/mod.rs @@ -462,7 +462,7 @@ impl CollatorStdImpl { )); } else { // last processed_to anchor in shard can be before last procssed in master - // it is normal, so we should not cancel collation buy we unable to import init anchors + // it is normal, so we should not cancel collation but we unable to import init anchors false } } else { diff --git a/collator/src/manager/mod.rs b/collator/src/manager/mod.rs index 0ade086f9..9a113efb6 100644 --- a/collator/src/manager/mod.rs +++ b/collator/src/manager/mod.rs @@ -1324,6 +1324,11 @@ where &mc_block_entry.top_shard_blocks_info, )?; + // when we run sync by any reason we should drop uncommitted queue updates + // after restoring the required state + // to avoid panics if next block was already collated before an it is incorrect + self.mq_adapter.clear_session_state()?; + let state = mc_block_entry.cached_state()?; // HACK: do not need to set master block latest chain time from zerostate when using mempool stub