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(health): measure continuous focus faults and verify disk-full recovery

Louis Beaumontb1266c89f19f
diff --git a/crates/screenpipe-db/tests/physical_disk_full_vm_test.rs b/crates/screenpipe-db/tests/physical_disk_full_vm_test.rs
new file mode 100644
index 000000000..dd38617e6
--- /dev/null
+++ b/crates/screenpipe-db/tests/physical_disk_full_vm_test.rs
@@ -0,0 +1,97 @@
+// screenpipe — AI that knows everything you've seen, said, or heard
+// https://screenpipe.com
+//! Manual acceptance on a disposable, separately mounted <=256 MiB volume.
+//! Never point this at a user's data volume. The harness requires an exact
+//! opt-in mount path and a task-created marker, and writes at most 256 MiB.
+use screenpipe_config::{DbConfig, DeviceTier};
+use screenpipe_db::DatabaseManager;
+use std::io::Write;
+
+#[tokio::test]
+#[ignore = "requires a disposable Mac VM and /Volumes/ScreenpipeFaultFixture"]
+async fn physical_disk_full_retires_writer_and_recovers_existing_database() {
+ assert_eq!(
+ std::env::var("SCREENPIPE_ISOLATED_VM_TEST").as_deref(),
+ Ok("1")
+ );
+ let root = std::path::Path::new("/Volumes/ScreenpipeFaultFixture");
+ assert!(root.join(".screenpipe-disposable-volume").is_file());
+ let dir = tempfile::tempdir_in(root).unwrap();
+ let path = dir.path().join("db.sqlite");
+ let config = DbConfig::for_tier(DeviceTier::Low);
+ let db = DatabaseManager::new(path.to_str().unwrap(), config.clone())
+ .await
+ .unwrap();
+ db.insert_audio_chunk("/fixture/before-full", None)
+ .await
+ .unwrap();
+ let filler_path = dir.path().join("capacity-filler");
+ let mut filler = std::fs::File::create_new(&filler_path).unwrap();
+ let block = vec![0x5a; 1024 * 1024];
+ let mut exhausted = false;
+ for _ in 0..256 {
+ if let Err(error) = filler.write_all(&block) {
+ assert_eq!(
+ error.raw_os_error(),
+ Some(28),
+ "expected real ENOSPC: {error}"
+ );
+ exhausted = true;
+ break;
+ }
+ }
+ assert!(
+ exhausted,
+ "fixture is not a small full volume; refusing further writes"
+ );
+ let _ = filler.sync_all();
+ let mut failed = false;
+ for index in 0..16 {
+ let large_path = format!("/fixture/full-{index}/{}", "x".repeat(128 * 1024));
+ match db.insert_audio_chunk(&large_path, None).await {
+ Ok(_) => continue,
+ Err(error) => {
+ eprintln!("physical capacity failure: {error}");
+ failed = true;
+ break;
+ }
+ }
+ }
+ assert!(failed, "writes must stop at real capacity exhaustion");
+ assert!(
+ db.write_queue_health().is_hard_faulted(),
+ "full disk must retire admission"
+ );
+ assert_eq!(
+ screenpipe_sqlite_coordinator::registered_sqlite_hard_fault(&path),
+ Some(13),
+ "the coordinator must identify SQLITE_FULL"
+ );
+ drop(filler);
+ std::fs::remove_file(&filler_path).unwrap();
+ db.close().await;
+ let resumed = DatabaseManager::new(path.to_str().unwrap(), config.clone())
+ .await
+ .unwrap();
+ resumed
+ .insert_audio_chunk("/fixture/after-capacity-returned", None)
+ .await
+ .unwrap();
+ resumed.close().await;
+ // Verify across another close/reopen, not from the writer's own live pool.
+ let verified = DatabaseManager::new(path.to_str().unwrap(), config)
+ .await
+ .unwrap();
+ assert!(verified
+ .find_audio_chunk_id("/fixture/before-full")
+ .await
+ .unwrap()
+ .is_some());
+ assert!(verified
+ .find_audio_chunk_id("/fixture/after-capacity-returned")
+ .await
+ .unwrap()
+ .is_some());
+ verified.close().await;
+ eprintln!("verified: ENOSPC, hard-faulted writer, existing rows preserved, new durable write after recovery");
+}
diff --git a/crates/screenpipe-engine/src/focus_aware_controller.rs b/crates/screenpipe-engine/src/focus_aware_controller.rs
index 619e0fff7..5d065816c 100644
--- a/crates/screenpipe-engine/src/focus_aware_controller.rs
+++ b/crates/screenpipe-engine/src/focus_aware_controller.rs
@@ -90,6 +90,8 @@ pub struct FocusAwareController {
/// nothing arrives for `STALE_FOCUS_CUTOFF`, we treat the state as
/// Unknown so all monitors stay Active (safe default).
last_event_time: Mutex<Instant>,
+ /// Health grace measures continuous unresolved time, not notification age.
+ unresolved_since: Mutex<Option<Instant>>,
/// Per-monitor Notify used to wake Cold capture loops when focus returns.
monitor_notifies: Mutex<HashMap<u32, Arc<Notify>>>,
stop_flag: Arc<AtomicBool>,
@@ -97,11 +99,13 @@ pub struct FocusAwareController {
impl FocusAwareController {
pub fn new(tracker: Arc<dyn FocusTracker>) -> Arc<Self> {
+ let unresolved_since = tracker.current().is_none().then(Instant::now);
let ctrl = Arc::new(Self {
tracker,
last_focus_time: Mutex::new(HashMap::new()),
current_focus: Mutex::new(None),
last_event_time: Mutex::new(Instant::now()),
+ unresolved_since: Mutex::new(unresolved_since),
monitor_notifies: Mutex::new(HashMap::new()),
stop_flag: Arc::new(AtomicBool::new(false)),
});
@@ -150,6 +154,10 @@ impl FocusAwareController {
}
fn apply_focus(&self, identity: MonitorIdentity) {
+ *self
+ .unresolved_since
+ .lock()
+ .expect("focus health mutex poisoned") = None;
let prev = {
let mut current = self
.current_focus
@@ -180,6 +188,10 @@ impl FocusAwareController {
}
fn apply_unknown(&self) {
+ self.unresolved_since
+ .lock()
+ .expect("focus health mutex poisoned")
+ .get_or_insert_with(Instant::now);
{
let mut current = self
.current_focus
@@ -220,14 +232,16 @@ impl FocusAwareController {
/// A long-lived unresolved tracker must be visible to health consumers.
/// Keep capture fail-closed: never attach global AX to an arbitrary display.
pub fn resolution_degraded(&self) -> bool {
- let stale = self
- .last_event_time
+ let resolved = self.tracker.current().is_some();
+ let mut since = self
+ .unresolved_since
.lock()
- .ok()
- .is_some_and(|time| time.elapsed() >= STALE_FOCUS_CUTOFF);
- // A quiet event stream is normal. The platform's independent poll
- // remains authoritative; only unresolved focus after grace is a fault.
- stale && self.tracker.current().is_none()
+ .expect("focus health mutex poisoned");
+ if resolved {
+ *since = None;
+ return false;
+ }
+ since.get_or_insert_with(Instant::now).elapsed() >= STALE_FOCUS_CUTOFF
}
fn hosts_focus_for_identity(&self, identity: &MonitorIdentity) -> bool {
@@ -471,13 +485,24 @@ mod tests {
ctrl.set_unknown_for_test();
assert!(!ctrl.resolution_degraded());
ctrl.backdate_last_event_for_test(Instant::now() - Duration::from_secs(60));
+ *ctrl.unresolved_since.lock().unwrap() = Some(Instant::now() - Duration::from_secs(29));
+ assert!(!ctrl.resolution_degraded());
+ *ctrl.unresolved_since.lock().unwrap() = Some(Instant::now() - STALE_FOCUS_CUTOFF);
+ ctrl.apply_unknown(); // repeated unresolved notifications must not renew grace
assert!(!ctrl.hosts_focus(1));
assert!(!ctrl.hosts_focus(2));
assert!(ctrl.resolution_degraded());
- *tracker.current.lock().unwrap() = Some(identity);
+ *tracker.current.lock().unwrap() = Some(identity.clone());
+ ctrl.apply_focus(identity);
assert!(!ctrl.resolution_degraded());
assert!(ctrl.hosts_focus(1));
assert!(!ctrl.hosts_focus(2));
+ *tracker.current.lock().unwrap() = None;
+ ctrl.apply_unknown();
+ assert!(
+ !ctrl.resolution_degraded(),
+ "a new failure gets a new grace period"
+ );
}
#[tokio::test]
diff --git a/crates/screenpipe-engine/src/routes/health.rs b/crates/screenpipe-engine/src/routes/health.rs
index 2bbf0ffb3..dce9876fa 100644
--- a/crates/screenpipe-engine/src/routes/health.rs
+++ b/crates/screenpipe-engine/src/routes/health.rs
@@ -102,10 +102,13 @@ fn vision_persistence_stalled(
now: u64,
last_attempt: u64,
last_progress: u64,
+ uptime_secs: f64,
threshold: u64,
) -> bool {
+ if uptime_secs <= 120.0 || last_attempt == 0 {
+ return false;
+ }
let capture_fresh = now.saturating_sub(last_attempt) < threshold;
- // Caller already gates this on >120s uptime and a real capture attempt.
// Never having made progress is a failure after warm-up, not perpetual startup.
let db_stale = last_progress == 0 || now.saturating_sub(last_progress) > threshold;
capture_fresh && db_stale
@@ -115,14 +118,37 @@ fn vision_persistence_stalled(
mod persistence_startup_regression {
use super::vision_persistence_stalled;
#[test]
+ fn startup_and_freshness_boundaries_and_recovery() {
+ for (attempt, progress, uptime, expected) in [
+ (999, 0, 119.0, false),
+ (999, 0, 120.0, false),
+ (999, 0, 120.001, true),
+ (0, 0, 300.0, false),
+ (940, 0, 300.0, false),
+ (941, 0, 300.0, true),
+ (999, 940, 300.0, false),
+ (999, 939, 300.0, true),
+ (999, 999, 300.0, false),
+ (999, 1001, 300.0, false),
+ ] {
+ assert_eq!(
+ vision_persistence_stalled(1000, attempt, progress, uptime, 60),
+ expected,
+ "attempt={attempt} progress={progress} uptime={uptime}"
+ );
+ }
+ assert!(vision_persistence_stalled(1000, 999, 0, 300.0, 60));
+ assert!(!vision_persistence_stalled(1001, 1001, 1001, 301.0, 60));
+ }
+ #[test]
fn active_capture_with_no_success_after_warmup_is_stalled() {
- assert!(vision_persistence_stalled(1000, 999, 0, 60));
+ assert!(vision_persistence_stalled(1000, 999, 0, 121.0, 60));
}
#[test]
fn recent_progress_and_idle_capture_are_not_write_stalls() {
- assert!(!vision_persistence_stalled(1000, 999, 990, 60));
- assert!(!vision_persistence_stalled(1000, 800, 800, 60));
- assert!(vision_persistence_stalled(1000, 999, 800, 60));
+ assert!(!vision_persistence_stalled(1000, 999, 990, 121.0, 60));
+ assert!(!vision_persistence_stalled(1000, 800, 800, 121.0, 60));
+ assert!(vision_persistence_stalled(1000, 999, 800, 121.0, 60));
}
}
@@ -755,6 +781,7 @@ pub struct HealthCheckResponse {
/// macOS monitor focus has remained unresolved beyond the grace period.
#[serde(default)]
pub vision_focus_unresolved: bool,
+ /// Capture attempts are fresh but persistence progress is stale after warm-up.
#[serde(default)]
pub vision_db_write_stalled: bool,
/// True when audio devices are active but DB writes have stopped (pool exhaustion).
@@ -1353,13 +1380,12 @@ async fn health_check_inner(state: &Arc<AppState>) -> HealthCheckResponse {
// — data is being captured but silently lost.
let vision_db_write_stalled = if !state.vision_disabled
&& vision_capture_expected
- && vision_snap.last_capture_attempt_ts > 0
- && vision_snap.uptime_secs > 120.0
{
let stalled = vision_persistence_stalled(
now_ts,
vision_snap.last_capture_attempt_ts,
vision_snap.last_db_write_ts,
+ vision_snap.uptime_secs,
threshold_secs,
);
diff --git a/docs/COVERAGE.md b/docs/COVERAGE.md
index 4acfbc30f..9a5a6043b 100644
--- a/docs/COVERAGE.md
+++ b/docs/COVERAGE.md
@@ -37,16 +37,16 @@ results and `cargo llvm-cov` data on top when judging release confidence.
### Core Engine
- Mapped suites: 37
-- Mapped Rust files: 399
-- Active test blocks: 3893
-- Ignored/manual test blocks: 184
-- Weighted coverage points: 3207.3
+- Mapped Rust files: 400
+- Active test blocks: 3894
+- Ignored/manual test blocks: 185
+- Weighted coverage points: 3208.0
| Platform | Suites | Active tests | Ignored tests | Weighted points | Layers | Flows | Critical score |
| --- | --- | --- | --- | --- | --- | --- | --- |
-| windows | 33 | 3730 | 166 | 3134.3 | 21 | 11 | 100% |
-| macos | 32 | 3773 | 145 | 3129.6 | 22 | 11 | 100% |
-| linux | 29 | 3308 | 141 | 2752.6 | 20 | 11 | 100% |
+| windows | 33 | 3731 | 167 | 3135.0 | 21 | 11 | 100% |
+| macos | 32 | 3774 | 146 | 3130.3 | 22 | 11 | 100% |
+| linux | 29 | 3309 | 142 | 2753.3 | 20 | 11 | 100% |
## Refresh
diff --git a/docs/coverage/CORE.md b/docs/coverage/CORE.md
index 4901dacec..29d2d7297 100644
--- a/docs/coverage/CORE.md
+++ b/docs/coverage/CORE.md
@@ -8,11 +8,11 @@ confidence, and criticality.
- Manifest: `docs/coverage/core-engine-map.json`
- Tracked crates: screenpipe-engine, screenpipe-db, screenpipe-sqlite-coordinator, screenpipe-audio, screenpipe-screen, screenpipe-a11y, screenpipe-fs
- Mapped suites: 37
-- Mapped Rust files: 399
-- Active test blocks: 3893
-- Ignored/manual test blocks: 184
-- Declared test blocks: 4077
-- Weighted coverage points: 3207.3
+- Mapped Rust files: 400
+- Active test blocks: 3894
+- Ignored/manual test blocks: 185
+- Declared test blocks: 4079
+- Weighted coverage points: 3208.0
Confidence weights: strong=1.0, partial=0.7, conditional=0.4, smoke=0.3.
Criticality weights: high=1.0, medium=0.7, low=0.4.
@@ -23,16 +23,16 @@ are explicitly enabled in a runtime lane.
| Platform | Suites | Active tests | Ignored tests | Weighted points | Layers | Flows | Critical score |
| --- | --- | --- | --- | --- | --- | --- | --- |
-| windows | 33 | 3730 | 166 | 3134.3 | 21 | 11 | 100% |
-| macos | 32 | 3773 | 145 | 3129.6 | 22 | 11 | 100% |
-| linux | 29 | 3308 | 141 | 2752.6 | 20 | 11 | 100% |
+| windows | 33 | 3731 | 167 | 3135.0 | 21 | 11 | 100% |
+| macos | 32 | 3774 | 146 | 3130.3 | 22 | 11 | 100% |
+| linux | 29 | 3309 | 142 | 2753.3 | 20 | 11 | 100% |
## Crate Summary
| Crate | Suites | Integration files | Source unit files | Active tests | Ignored tests | Weighted points | Flows |
| --- | --- | --- | --- | --- | --- | --- | --- |
-| screenpipe-engine | 12 | 22 | 131 | 1862 | 53 | 1434.1 | 10 |
-| screenpipe-db | 5 | 68 | 28 | 629 | 31 | 599.4 | 9 |
+| screenpipe-engine | 12 | 22 | 131 | 1863 | 53 | 1434.8 | 10 |
+| screenpipe-db | 5 | 69 | 28 | 629 | 32 | 599.4 | 9 |
| screenpipe-sqlite-coordinator | 1 | 0 | 3 | 27 | 0 | 27.0 | 2 |
| screenpipe-audio | 8 | 29 | 53 | 695 | 53 | 606.9 | 5 |
| screenpipe-screen | 6 | 9 | 19 | 276 | 9 | 245.4 | 4 |
@@ -66,22 +66,22 @@ bun run coverage:core -- --llvm-cov-summary ../../docs/coverage/core-llvm-cov-su
| audio | 10 suites / 833 active / 57 ignored / 744.9 pts | 9 suites / 827 active / 57 ignored / 740.7 pts | 8 suites / 748 active / 56 ignored / 685.4 pts |
| audio-device | 2 suites / 235 active / 7 ignored / 211.3 pts | 2 suites / 235 active / 7 ignored / 211.3 pts | 1 suites / 156 active / 6 ignored / 156.0 pts |
| configuration | 2 suites / 153 active / 3 ignored / 138.7 pts | 2 suites / 153 active / 3 ignored / 138.7 pts | 2 suites / 153 active / 3 ignored / 138.7 pts |
-| database | 7 suites / 585 active / 27 ignored / 555.4 pts | 7 suites / 585 active / 27 ignored / 555.4 pts | 7 suites / 585 active / 27 ignored / 555.4 pts |
+| database | 7 suites / 585 active / 28 ignored / 555.4 pts | 7 suites / 585 active / 28 ignored / 555.4 pts | 7 suites / 585 active / 28 ignored / 555.4 pts |
| db-search | 2 suites / 120 active / 9 ignored / 120.0 pts | 2 suites / 120 active / 9 ignored / 120.0 pts | 2 suites / 120 active / 9 ignored / 120.0 pts |
| engine-lifecycle | 6 suites / 270 active / 1 ignored / 242.0 pts | 6 suites / 270 active / 1 ignored / 242.0 pts | 6 suites / 266 active / 9 ignored / 241.1 pts |
-| local-api | 3 suites / 484 active / 12 ignored / 342.7 pts | 3 suites / 484 active / 12 ignored / 342.7 pts | 3 suites / 484 active / 12 ignored / 342.7 pts |
-| meeting | 6 suites / 1756 active / 32 ignored / 1436.5 pts | 6 suites / 1756 active / 32 ignored / 1436.5 pts | 4 suites / 1402 active / 28 ignored / 1106.2 pts |
+| local-api | 3 suites / 485 active / 12 ignored / 343.4 pts | 3 suites / 485 active / 12 ignored / 343.4 pts | 3 suites / 485 active / 12 ignored / 343.4 pts |
+| meeting | 6 suites / 1757 active / 32 ignored / 1437.2 pts | 6 suites / 1757 active / 32 ignored / 1437.2 pts | 4 suites / 1403 active / 28 ignored / 1106.9 pts |
| ocr | 4 suites / 141 active / 7 ignored / 130.8 pts | 4 suites / 134 active / 7 ignored / 128.6 pts | 3 suites / 125 active / 6 ignored / 119.6 pts |
| os-integration | 1 suites / 6 active / 0 ignored / 1.7 pts | 1 suites / 6 active / 0 ignored / 1.7 pts | - |
-| performance | 13 suites / 1686 active / 82 ignored / 1488.5 pts | 14 suites / 1811 active / 90 ignored / 1538.5 pts | 13 suites / 1686 active / 82 ignored / 1488.5 pts |
+| performance | 13 suites / 1686 active / 83 ignored / 1488.5 pts | 14 suites / 1811 active / 91 ignored / 1538.5 pts | 13 suites / 1686 active / 83 ignored / 1488.5 pts |
| pipes | 1 suites / 551 active / 3 ignored / 385.7 pts | 1 suites / 551 active / 3 ignored / 385.7 pts | 1 suites / 551 active / 3 ignored / 385.7 pts |
| privacy | 5 suites / 1013 active / 42 ignored / 816.8 pts | 5 suites / 1069 active / 21 ignored / 818.5 pts | 5 suites / 971 active / 14 ignored / 781.7 pts |
| real-app | - | 1 suites / 125 active / 8 ignored / 50.0 pts | - |
| speaker | 2 suites / 416 active / 18 ignored / 416.0 pts | 2 suites / 416 active / 18 ignored / 416.0 pts | 2 suites / 416 active / 18 ignored / 416.0 pts |
| storage | 4 suites / 690 active / 41 ignored / 575.4 pts | 4 suites / 690 active / 41 ignored / 575.4 pts | 4 suites / 690 active / 41 ignored / 575.4 pts |
| sync | 1 suites / 551 active / 3 ignored / 385.7 pts | 1 suites / 551 active / 3 ignored / 385.7 pts | 1 suites / 551 active / 3 ignored / 385.7 pts |
-| timeline | 4 suites / 1243 active / 48 ignored / 1020.4 pts | 4 suites / 1243 active / 48 ignored / 1020.4 pts | 4 suites / 1243 active / 48 ignored / 1020.4 pts |
-| transcription | 7 suites / 895 active / 53 ignored / 700.1 pts | 6 suites / 889 active / 53 ignored / 695.9 pts | 6 suites / 889 active / 53 ignored / 695.9 pts |
+| timeline | 4 suites / 1244 active / 48 ignored / 1021.1 pts | 4 suites / 1244 active / 48 ignored / 1021.1 pts | 4 suites / 1244 active / 48 ignored / 1021.1 pts |
+| transcription | 7 suites / 896 active / 53 ignored / 700.8 pts | 6 suites / 890 active / 53 ignored / 696.6 pts | 6 suites / 890 active / 53 ignored / 696.6 pts |
| ui-events | 4 suites / 828 active / 34 ignored / 627.7 pts | 3 suites / 759 active / 5 ignored / 579.4 pts | 3 suites / 759 active / 5 ignored / 579.4 pts |
| vision-capture | 6 suites / 577 active / 32 ignored / 454.3 pts | 6 suites / 570 active / 32 ignored / 452.1 pts | 5 suites / 561 active / 31 ignored / 443.1 pts |
@@ -133,10 +133,10 @@ bun run coverage:core -- --llvm-cov-summary ../../docs/coverage/core-llvm-cov-su
| audio-windows-parakeet-provider | screenpipe-audio | windows | audio, transcription | audio-record-transcribe | high | partial | unit | 1 | 6 | 0 | Registers existing CPU override, eligible adapter selection, DXGI ordinal, error fallback and adapter determinism tests. Windows-only; manifest registration does not verify execution on physical GPU hardware. |
| db-accessibility-ui-events | screenpipe-db | windows, macos, linux | database, configuration, accessibility, ui-events, performance | settings-to-engine-config, accessibility-ui-events, performance-liveness | medium | partial | integration | 7 | 28 | 2 | Elements bulk insert, on-screen filtering, UI event batching, DB tier config, and ignored heavy-read real-DB probes. |
| db-audio-meetings-speakers | screenpipe-db | windows, macos, linux | database, audio, meeting, speaker | audio-record-transcribe, audio-device-health, meeting-live-notes | high | strong | integration | 19 | 135 | 4 | Audio transcript dedupe, live meeting mirroring, end-generation and open-meeting invariants, liveness, and speaker reassignment coverage. |
-| db-runtime-reliability | screenpipe-db | windows, macos, linux | database, performance | performance-liveness | high | partial | mixed | 17 | 51 | 6 | SQLite hard-fault classification, failpoint VFS injection, fresh-identity recovery verification with integrity/FK/write canaries, query cancellation, close-severs-connections regressions, multi-pool WAL parity, runtime version pinning, and WAL chaos plus memory-pressure probes, plus read-only quarantine self-heal verification for transient IOERR faults. |
+| db-runtime-reliability | screenpipe-db | windows, macos, linux | database, performance | performance-liveness | high | partial | mixed | 18 | 51 | 7 | SQLite hard-fault classification, failpoint VFS injection, fresh-identity recovery verification with integrity/FK/write canaries, query cancellation, close-severs-connections regressions, multi-pool WAL parity, runtime version pinning, and WAL chaos plus memory-pressure probes, plus read-only quarantine self-heal verification for transient IOERR faults. |
| db-search-indexing | screenpipe-db | windows, macos, linux | db-search, ocr, accessibility, performance | local-api-search, capture-ocr-pipeline, accessibility-ui-events, performance-liveness | high | strong | mixed | 14 | 107 | 4 | FTS, tokenizer, OCR snapshot search, query planning, ordering, accessibility search, and contention coverage. |
| db-timeline-frames | screenpipe-db | windows, macos, linux | database, timeline, storage, performance | timeline-streaming, performance-liveness | high | strong | mixed | 39 | 308 | 15 | Frame/audio joins, timeline query shape, suggestions frames, write queue, DB primitives (src/db.rs split into src/db/ modules), feedback record upserts, media eviction anti-join regressions, SAF output registry, semantic storage, and timeline performance. |
-| engine-api-routes | screenpipe-engine | windows, macos, linux | local-api, timeline, meeting, transcription | local-api-search, timeline-streaming, meeting-live-notes, audio-record-transcribe | high | partial | mixed | 46 | 435 | 7 | Route/unit coverage for search, health, streaming, meetings, time/timezone, and transcription. Legacy endpoint/websocket tests require local data and remain ignored. |
+| engine-api-routes | screenpipe-engine | windows, macos, linux | local-api, timeline, meeting, transcription | local-api-search, timeline-streaming, meeting-live-notes, audio-record-transcribe | high | partial | mixed | 46 | 436 | 7 | Route/unit coverage for search, health, streaming, meetings, time/timezone, and transcription. Legacy endpoint/websocket tests require local data and remain ignored. |
| engine-capture-timeline | screenpipe-engine | windows, macos, linux | vision-capture, timeline, storage, performance | capture-ocr-pipeline, timeline-streaming, performance-liveness | high | partial | mixed | 25 | 307 | 26 | Covers capture trigger logic, frame/audio linking, hot cache, timeline refresh regressions, fragmented MP4 extraction, and HD-mode control. Several real-data tests are intentionally ignored by default. |
| engine-config-lifecycle | screenpipe-engine | windows, macos, linux | configuration, engine-lifecycle, performance | settings-to-engine-config, engine-health-lifecycle, performance-liveness | high | strong | mixed | 13 | 125 | 1 | Fast logic coverage for the config bridge, health-endpoint identity, tray health debounce, sleep/power policies, and queue backpressure. |
| engine-db-recovery-cli | screenpipe-engine | windows, macos, linux | database, engine-lifecycle | engine-health-lifecycle, performance-liveness | high | strong | unit | 1 | 33 | 0 | Exact DB/WAL/SHM working-copy preservation, rollback on archive failure, and restart repair for crashes during the multi-file generation swap. |
@@ -347,6 +347,7 @@ bun run coverage:core -- --llvm-cov-summary ../../docs/coverage/core-llvm-cov-su
| db-audio-meetings-speakers | screenpipe-db | tests/output_audio_liveness_test.rs | integration | 8 | 0 | 8 |
| db-search-indexing | screenpipe-db | tests/output_search_test.rs | integration | 9 | 0 | 9 |
| db-timeline-frames | screenpipe-db | tests/outputs_saf_test.rs | integration | 5 | 0 | 5 |
+| db-runtime-reliability | screenpipe-db | tests/physical_disk_full_vm_test.rs | integration | 0 | 1 | 1 |
| db-runtime-reliability | screenpipe-db | tests/quarantine_self_heal_test.rs | integration | 8 | 0 | 8 |
| db-search-indexing | screenpipe-db | tests/query_plan_test.rs | integration | 19 | 0 | 19 |
| db-timeline-frames | screenpipe-db | tests/range_export_frame_sources_test.rs | integration | 3 | 0 | 3 |
@@ -465,7 +466,7 @@ bun run coverage:core -- --llvm-cov-summary ../../docs/coverage/core-llvm-cov-su
| engine-api-routes | screenpipe-engine | src/routes/data.rs | source | 2 | 0 | 2 |
| engine-api-routes | screenpipe-engine | src/routes/elements.rs | source | 25 | 1 | 26 |
| engine-api-routes | screenpipe-engine | src/routes/frames.rs | source | 12 | 1 | 13 |
-| engine-api-routes | screenpipe-engine | src/routes/health.rs | source | 56 | 0 | 56 |
+| engine-api-routes | screenpipe-engine | src/routes/health.rs | source | 57 | 0 | 57 |
| engine-api-routes | screenpipe-engine | src/routes/live_views.rs | source | 1 | 0 | 1 |
| engine-api-routes | screenpipe-engine | src/routes/meeting_summary_status.rs | source | 11 | 0 | 11 |
| engine-api-routes | screenpipe-engine | src/routes/meetings.rs | source | 7 | 0 | 7 |
diff --git a/docs/coverage/core-engine-map.json b/docs/coverage/core-engine-map.json
index fa48ccbd1..dcaacb454 100644
--- a/docs/coverage/core-engine-map.json
+++ b/docs/coverage/core-engine-map.json
@@ -754,6 +754,7 @@
"tests/cancellable_query_test.rs",
"tests/cancellation_performance_bench.rs",
"tests/close_severs_connections_test.rs",
+ "tests/physical_disk_full_vm_test.rs",
"tests/hybrid_recovery.rs",
"tests/memory_pressure_test.rs",
"tests/multi_pool_wal_parity_test.rs",