Skip to main content

max / synckit

document the keychain-disabled keystore stubs The no-op store_key and delete_key stubs behind cfg(not(feature = "keychain")) had no docs, which tripped missing_docs for any consumer building with --no-default-features.
Co-Authored-By
Claude Opus 5 (1M context) <noreply@anthropic.com>
Author: Max Johnson <me@maxj.phd> · 2026-08-01 21:28 UTC
Signed with PGP, not checked
Commit: 5c0abd855c180309fa0e46e84ddb7974e82a690b
Parent: 5692900
1 file changed, +8 insertions, -0 deletions
@@ -237,6 +237,10 @@
237 237
238 238 // ── No-op stubs when keychain feature is disabled ──
239 239
240 + /// Store the master key in the OS keychain.
241 + ///
242 + /// No-op stub built when the `keychain` feature is off: the key is not
243 + /// persisted and a warning is logged. Always `Ok`.
240 244 #[cfg(not(feature = "keychain"))]
241 245 pub fn store_key(_app_id: AppId, _user_id: UserId, _master_key: &[u8; 32]) -> Result<()> {
242 246 tracing::warn!("Keychain support disabled, master key not persisted");
@@ -251,6 +255,10 @@
251 255 Ok(None)
252 256 }
253 257
258 + /// Delete the master key from the OS keychain.
259 + ///
260 + /// No-op stub built when the `keychain` feature is off: nothing was stored, so
261 + /// nothing is deleted. Always `Ok`.
254 262 #[cfg(not(feature = "keychain"))]
255 263 pub fn delete_key(_app_id: AppId, _user_id: UserId) -> Result<()> {
256 264 Ok(())