(dir: &Path, run_id: &str)
| 519 | } |
| 520 | |
| 521 | fn remove_lifecycle(dir: &Path, run_id: &str) -> CliResult<()> { |
| 522 | validate_run_id(run_id)?; |
| 523 | match fs::remove_file(lifecycle_path(dir, run_id)) { |
| 524 | Ok(()) => Ok(()), |
| 525 | Err(e) if e.kind() == std::io::ErrorKind::NotFound => Ok(()), |
| 526 | Err(e) => Err(CliError::Internal(anyhow!( |
| 527 | "failed to remove managed lifecycle '{}': {}", |
| 528 | run_id, |
| 529 | e |
| 530 | ))), |
| 531 | } |
| 532 | } |
| 533 | |
| 534 | /// Collect sessions stamped with `run_id` from the canonical session store. |
| 535 | fn collect_run_sessions(dot_dir: &Path, run_id: &str) -> Vec<RunSessionSummary> { |
no test coverage detected