cloud: status, diff, apply (#7614)

Adds cli commands for getting the status of cloud tasks, and for
getting/applying the diffs from same.
This commit is contained in:
Jeremy Rose
2025-12-05 13:39:23 -08:00
committed by GitHub
parent f48d88067e
commit 2e4a402521
10 changed files with 594 additions and 27 deletions

View File

@@ -350,6 +350,7 @@ pub enum AppEvent {
mod tests {
use super::*;
use chrono::Utc;
use codex_cloud_tasks_client::CloudTaskError;
struct FakeBackend {
// maps env key to titles
@@ -385,6 +386,17 @@ mod tests {
Ok(out)
}
async fn get_task_summary(
&self,
id: TaskId,
) -> codex_cloud_tasks_client::Result<TaskSummary> {
self.list_tasks(None)
.await?
.into_iter()
.find(|t| t.id == id)
.ok_or_else(|| CloudTaskError::Msg(format!("Task {} not found", id.0)))
}
async fn get_task_diff(
&self,
_id: TaskId,