Fix state-db pinning (#12927)

* Pin all canonicalized blocks

* Added a test

* Docs
This commit is contained in:
Arkadiy Paronyan
2022-12-14 12:03:16 +01:00
committed by GitHub
parent 09ae802f9c
commit 68096de80c
3 changed files with 58 additions and 18 deletions
+1
View File
@@ -2002,6 +2002,7 @@ impl<Block: BlockT> sc_client_api::backend::Backend<Block> for Backend<Block> {
.map_err(sp_blockchain::Error::from_state_db)?;
Err(e)
} else {
self.storage.state_db.sync();
Ok(())
}
}