From b5bfb8ed6aca17983eeeded01818a6ab013fd15a Mon Sep 17 00:00:00 2001 From: Marko Vejnovic Date: Wed, 10 Jun 2026 14:05:44 -0700 Subject: [PATCH] fix(hm): pass NonZeroU64 capacity to ImageRegistry::open in cache clean main was broken: #117 changed ImageRegistry::open to take NonZeroU64, but the cache-clean caller still passed u64::MAX (E0308). It slipped in as a semantic merge (no textual conflict), so main's hm binary stopped compiling on stable. This unbreaks main; every open PR is red only because GitHub builds them merged with this broken main. --- crates/hm/src/commands/cache/clean.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/hm/src/commands/cache/clean.rs b/crates/hm/src/commands/cache/clean.rs index b9dcb80e..aa71cb02 100644 --- a/crates/hm/src/commands/cache/clean.rs +++ b/crates/hm/src/commands/cache/clean.rs @@ -55,7 +55,7 @@ pub async fn handle_clean() -> Result { /// cache index is reset. async fn remove_registered_images(db_path: &std::path::Path) { // Capacity here is irrelevant — we only read existing rows, never insert. - let registry = match hm_vm::ImageRegistry::open(db_path, u64::MAX) { + let registry = match hm_vm::ImageRegistry::open(db_path, std::num::NonZeroU64::MAX) { Ok(r) => r, Err(e) => { tracing::warn!(error = %e, "could not open image registry; skipping image removal");