From a67c96469d2d06e85c4be69a725af7b93fb023a2 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 19 Nov 2026 14:29:38 +0000 Subject: config: store-propose-versions is 1 unless set, in the settings too The option's help said 1 unless set, but the setting itself stayed unset, so a node proposed no checkpoint after a version unless told, and `options_and_settings_agree` failed: `default of store-propose-versions`, 1 against null. The setting is a count now, 1 unless set, and 0 has the node propose none after versions. --- src/config/mod.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/config/mod.rs') diff --git a/src/config/mod.rs b/src/config/mod.rs index 652a10e..0ed22a2 100644 --- a/src/config/mod.rs +++ b/src/config/mod.rs @@ -843,7 +843,8 @@ pub(crate) struct Settings { )] pub(crate) store_propose_every: Option, #[cfg(feature = "federation")] - pub(crate) store_propose_versions: Option, + #[serde(default = "default_store_propose_versions")] + pub(crate) store_propose_versions: u64, #[cfg(feature = "federation")] #[serde( default = "default_store_held_for", @@ -1051,6 +1052,10 @@ fn default_session_lifetime() -> Duration { fn default_store_held_for() -> Duration { Duration::from_secs(10 * 60) } +#[cfg(feature = "federation")] +fn default_store_propose_versions() -> u64 { + 1 +} fn default_challenge_lifetime() -> Duration { Duration::from_secs(5 * 60) } -- cgit v1.3.1