feat(#1104): surface full output file path in bash_status when truncated
This commit is contained in:
parent
cb5ee66311
commit
60047eb01d
2 changed files with 37 additions and 2 deletions
|
|
@ -30,8 +30,10 @@ use tokio::io::AsyncWriteExt;
|
|||
|
||||
const POLL_INTERVAL: Duration = Duration::from_millis(200);
|
||||
/// Soft cap on stdout/stderr captured in the done JSON summary.
|
||||
/// Full output always lives in the .out/.err files.
|
||||
const SUMMARY_BYTES: usize = 4096;
|
||||
/// Full output always lives in the .out/.err files. Exposed so
|
||||
/// `format_bash_status` can detect truncation and surface the full-output
|
||||
/// file path when the on-disk file is larger.
|
||||
pub const SUMMARY_BYTES: usize = 4096;
|
||||
/// Default timeout for tasks that don't specify one.
|
||||
pub const DEFAULT_TIMEOUT_SECS: u64 = 180;
|
||||
|
||||
|
|
@ -77,6 +79,20 @@ fn task_err(id: &str) -> PathBuf {
|
|||
tasks_dir().join(format!("{id}.err"))
|
||||
}
|
||||
|
||||
/// Path to the full stdout capture file for `id`.
|
||||
/// Exposed so `format_bash_status` can surface it when output is truncated.
|
||||
#[must_use]
|
||||
pub fn task_out_path(id: &str) -> PathBuf {
|
||||
task_out(id)
|
||||
}
|
||||
|
||||
/// Path to the full stderr capture file for `id`.
|
||||
/// Exposed so `format_bash_status` can surface it when output is truncated.
|
||||
#[must_use]
|
||||
pub fn task_err_path(id: &str) -> PathBuf {
|
||||
task_err(id)
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Wire types (shared between MCP tool writers and runner readers)
|
||||
// ---------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Reference in a new issue