Suppress errors for requested session stops

This commit is contained in:
iris committed 2026-09-12 20:49:38 -04:00
1 parent 76895bc644
commit 559e6c9226
5 files changed
+101 -18

No files matched your search

+7 -5
View File
@@ -802,11 +802,13 @@ async fn follow(
process::Liveness::Dead if complete > 0 => {}
process::Liveness::Dead => {
queue.lock().unwrap().close(&sink, "the session ended");
let detail = stderr_tail(&stderr_path);
if !detail.is_empty() {
let _ = sink.send(Event::Error {
message: format!("{label} exited:\n{detail}"),
});
if !process::stopping(&session_dir) {
let detail = stderr_tail(&stderr_path);
if !detail.is_empty() {
let _ = sink.send(Event::Error {
message: format!("{label} exited:\n{detail}"),
});
}
}
let _ = sink.send(Event::Status {
state: SessionStatus::Exited,