Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

fix: match numeric monitor IDs in health check filter

Louis Beaumontfa57851b1fc6
diff --git a/apps/screenpipe-app-tauri/src-tauri/src/health.rs b/apps/screenpipe-app-tauri/src-tauri/src/health.rs
index f282858e7..c8f7354a5 100644
--- a/apps/screenpipe-app-tauri/src-tauri/src/health.rs
+++ b/apps/screenpipe-app-tauri/src-tauri/src/health.rs
@@ -417,7 +417,12 @@ pub async fn start_health_check(app: tauri::AppHandle) -> Result<()> {
let health_name = d.name.split(" (").next().unwrap_or(&d.name);
let allowed_short =
allowed_name.split('_').next().unwrap_or(allowed_name);
- health_name == allowed_short
+ // Also match numeric monitor IDs from CLI -m flag
+ // e.g. allowed="3" should match health_name="Display 3"
+ let numeric_match = health_name
+ .strip_prefix("Display ")
+ .map_or(false, |id| id == *allowed);
+ health_name == allowed_short || numeric_match
})
});
}