first pass of merging in warp (doesn't build)

This commit is contained in:
Ryan Ward
2026-07-01 16:08:58 -05:00
parent 2f64909469
commit 4770ac06b5
3662 changed files with 414574 additions and 89772 deletions
+28
View File
@@ -14,6 +14,18 @@ pub struct HarnessSupportArgs {
pub command: HarnessSupportCommand,
}
impl HarnessSupportCommand {
pub(crate) fn as_str_for_tracing(&self) -> &'static str {
match self {
HarnessSupportCommand::Ping => "harness-support ping",
HarnessSupportCommand::ReportArtifact(_) => "harness-support report-artifact",
HarnessSupportCommand::NotifyUser(_) => "harness-support notify-user",
HarnessSupportCommand::FinishTask(_) => "harness-support finish-task",
HarnessSupportCommand::ReportShutdown(_) => "harness-support report-shutdown",
}
}
}
#[derive(Debug, Clone, Subcommand)]
pub enum HarnessSupportCommand {
/// Verify connectivity by fetching and displaying the current run.
@@ -28,6 +40,9 @@ pub enum HarnessSupportCommand {
/// Report task completion or failure, as well as a summary of the task.
FinishTask(FinishTaskArgs),
/// Report that the agent process is shutting down.
ReportShutdown(ReportShutdownArgs),
}
#[derive(Debug, Clone, Args)]
@@ -76,3 +91,16 @@ pub struct FinishTaskArgs {
#[arg(long)]
pub summary: String,
}
#[derive(Debug, Clone, Args)]
pub struct ReportShutdownArgs {
/// Error category for abnormal shutdown (e.g. "oom", "timeout").
/// Omit for clean shutdown.
#[arg(long)]
pub error_category: Option<String>,
/// Human-readable error message for abnormal shutdown.
/// Omit for clean shutdown.
#[arg(long)]
pub error_message: Option<String>,
}