mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-15 08:01:09 +00:00
Remove the --unsafe-pruning CLI-argument (step 1) (#10995)
* sc-client-db: utils::open_database(...) — return OpenDbError so that the caller could tell the `OpenDbError::DoesNotExist` clearly * sc-client-db: utils::open_database(..) — accept the `create: bool` argument * sc-client-db: pruning — optional argument in the DatabaseSettings * sc-state-db: Split `Error<E>` into separate `Error<E>` and `StateDbError` * StateDb::open: choose the pruning-mode depending on the requested and stored values * sc-state-db: test for different combinations of stored and requested pruning-modes * CLI-argument: mark the unsafe-pruning as deprecated * Fix tests * tests: do not specify --pruning when running the substrate over the existing storage * fix types for benches * cargo fmt * Check whether the pruning-mode and sync-mode are compatible * cargo fmt * parity-db: 0.3.11 -> 0.3.12 * sc-state-db: MetaDb::set_meta — a better doc-test * cargo fmt * make MetaDb read-only again! * Remove the stray newline (and run the CI once again please) * Last nitpicks * A more comprehensive error message
This commit is contained in:
committed by
GitHub
parent
994f8076b1
commit
729cba9d9e
@@ -1199,7 +1199,7 @@ fn doesnt_import_blocks_that_revert_finality() {
|
||||
DatabaseSettings {
|
||||
state_cache_size: 1 << 20,
|
||||
state_cache_child_ratio: None,
|
||||
state_pruning: PruningMode::ArchiveAll,
|
||||
state_pruning: Some(PruningMode::ArchiveAll),
|
||||
keep_blocks: KeepBlocks::All,
|
||||
source: DatabaseSource::RocksDb { path: tmp.path().into(), cache_size: 1024 },
|
||||
},
|
||||
@@ -1426,7 +1426,7 @@ fn returns_status_for_pruned_blocks() {
|
||||
DatabaseSettings {
|
||||
state_cache_size: 1 << 20,
|
||||
state_cache_child_ratio: None,
|
||||
state_pruning: PruningMode::keep_blocks(1),
|
||||
state_pruning: Some(PruningMode::keep_blocks(1)),
|
||||
keep_blocks: KeepBlocks::All,
|
||||
source: DatabaseSource::RocksDb { path: tmp.path().into(), cache_size: 1024 },
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user