From 9af9b7e008c6c4fbbcf8f642872f66dc6cbdd811 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Salavisa?= Date: Fri, 23 Jan 2026 17:37:16 +0000 Subject: [PATCH] refactor: remove progress field from TaskSession and AgentExecution (#75) --- .../internal/agent/controller/controller.go | 2 -- apps/backend/internal/agent/dto/dto.go | 3 -- .../internal/agent/lifecycle/event_types.go | 1 - .../internal/agent/lifecycle/events.go | 1 - .../internal/agent/lifecycle/manager.go | 1 - .../internal/agent/lifecycle/manager_test.go | 4 --- .../internal/agent/lifecycle/runtime.go | 1 - .../backend/internal/agent/lifecycle/types.go | 13 ++++---- .../orchestrator/executor/executor.go | 7 ----- apps/backend/internal/task/dto/dto.go | 2 -- apps/backend/internal/task/models/models.go | 2 -- .../internal/task/repository/sqlite.go | 31 +++++++++---------- .../internal/task/repository/sqlite_test.go | 5 --- .../domains/session/use-session-resumption.ts | 3 -- apps/web/lib/types/http.ts | 1 - apps/web/lib/ws/handlers/agent-session.ts | 2 -- 16 files changed, 21 insertions(+), 58 deletions(-) diff --git a/apps/backend/internal/agent/controller/controller.go b/apps/backend/internal/agent/controller/controller.go index bf035dec90..65b1c9cba6 100644 --- a/apps/backend/internal/agent/controller/controller.go +++ b/apps/backend/internal/agent/controller/controller.go @@ -42,7 +42,6 @@ func (c *Controller) ListAgents(ctx context.Context, req dto.ListAgentsRequest) AgentProfileID: a.AgentProfileID, ContainerID: a.ContainerID, Status: string(a.Status), - Progress: a.Progress, StartedAt: a.StartedAt, FinishedAt: a.FinishedAt, ExitCode: a.ExitCode, @@ -96,7 +95,6 @@ func (c *Controller) GetAgentStatus(ctx context.Context, req dto.GetAgentStatusR AgentProfileID: agent.AgentProfileID, ContainerID: agent.ContainerID, Status: string(agent.Status), - Progress: agent.Progress, StartedAt: agent.StartedAt, FinishedAt: agent.FinishedAt, ExitCode: agent.ExitCode, diff --git a/apps/backend/internal/agent/dto/dto.go b/apps/backend/internal/agent/dto/dto.go index 87817fc918..929f64d474 100644 --- a/apps/backend/internal/agent/dto/dto.go +++ b/apps/backend/internal/agent/dto/dto.go @@ -13,7 +13,6 @@ type AgentDTO struct { AgentProfileID string `json:"agent_profile_id"` ContainerID string `json:"container_id,omitempty"` Status string `json:"status"` - Progress int `json:"progress"` StartedAt string `json:"started_at"` FinishedAt string `json:"finished_at,omitempty"` ExitCode *int `json:"exit_code,omitempty"` @@ -96,7 +95,6 @@ func FromAgentExecution(execution *AgentExecutionData) AgentDTO { AgentProfileID: execution.AgentProfileID, ContainerID: execution.ContainerID, Status: execution.Status, - Progress: execution.Progress, StartedAt: execution.StartedAt.Format("2006-01-02T15:04:05Z"), } if execution.FinishedAt != nil && !execution.FinishedAt.IsZero() { @@ -118,7 +116,6 @@ type AgentExecutionData struct { AgentProfileID string ContainerID string Status string - Progress int StartedAt time.Time FinishedAt *time.Time ExitCode *int diff --git a/apps/backend/internal/agent/lifecycle/event_types.go b/apps/backend/internal/agent/lifecycle/event_types.go index f963d8c2c5..cf268cabb7 100644 --- a/apps/backend/internal/agent/lifecycle/event_types.go +++ b/apps/backend/internal/agent/lifecycle/event_types.go @@ -12,7 +12,6 @@ type AgentEventPayload struct { Status string `json:"status"` StartedAt time.Time `json:"started_at"` FinishedAt *time.Time `json:"finished_at,omitempty"` - Progress int `json:"progress"` ErrorMessage string `json:"error_message,omitempty"` ExitCode *int `json:"exit_code,omitempty"` } diff --git a/apps/backend/internal/agent/lifecycle/events.go b/apps/backend/internal/agent/lifecycle/events.go index b0ead55571..fba5f0361d 100644 --- a/apps/backend/internal/agent/lifecycle/events.go +++ b/apps/backend/internal/agent/lifecycle/events.go @@ -42,7 +42,6 @@ func (p *EventPublisher) PublishAgentEvent(ctx context.Context, eventType string Status: string(execution.Status), StartedAt: execution.StartedAt, FinishedAt: execution.FinishedAt, - Progress: execution.Progress, ErrorMessage: execution.ErrorMessage, ExitCode: execution.ExitCode, } diff --git a/apps/backend/internal/agent/lifecycle/manager.go b/apps/backend/internal/agent/lifecycle/manager.go index 89f0caa31c..6ce5e1f581 100644 --- a/apps/backend/internal/agent/lifecycle/manager.go +++ b/apps/backend/internal/agent/lifecycle/manager.go @@ -1510,7 +1510,6 @@ func (m *Manager) MarkCompleted(executionID string, exitCode int, errorMessage s if exitCode == 0 && errorMessage == "" { exec.Status = v1.AgentStatusCompleted - exec.Progress = 100 } else { exec.Status = v1.AgentStatusFailed } diff --git a/apps/backend/internal/agent/lifecycle/manager_test.go b/apps/backend/internal/agent/lifecycle/manager_test.go index 9e07d192a7..6fc22a9987 100644 --- a/apps/backend/internal/agent/lifecycle/manager_test.go +++ b/apps/backend/internal/agent/lifecycle/manager_test.go @@ -287,7 +287,6 @@ func TestManager_MarkCompleted_Success(t *testing.T) { ContainerID: "container-123", Status: v1.AgentStatusRunning, StartedAt: time.Now(), - Progress: 50, } mgr.executionStore.Add(execution) @@ -302,9 +301,6 @@ func TestManager_MarkCompleted_Success(t *testing.T) { if got.Status != v1.AgentStatusCompleted { t.Errorf("expected status %v, got %v", v1.AgentStatusCompleted, got.Status) } - if got.Progress != 100 { - t.Errorf("expected progress 100, got %d", got.Progress) - } if got.FinishedAt == nil { t.Error("expected FinishedAt to be set") } diff --git a/apps/backend/internal/agent/lifecycle/runtime.go b/apps/backend/internal/agent/lifecycle/runtime.go index 13a90d53a7..263aa83309 100644 --- a/apps/backend/internal/agent/lifecycle/runtime.go +++ b/apps/backend/internal/agent/lifecycle/runtime.go @@ -109,7 +109,6 @@ func (ri *RuntimeInstance) ToAgentExecution(req *RuntimeCreateRequest) *AgentExe WorkspacePath: workspacePath, Status: v1.AgentStatusRunning, StartedAt: time.Now(), - Progress: 0, Metadata: metadata, agentctl: ri.Client, standaloneInstanceID: ri.StandaloneInstanceID, diff --git a/apps/backend/internal/agent/lifecycle/types.go b/apps/backend/internal/agent/lifecycle/types.go index 036d0b57e3..3b228a5f1e 100644 --- a/apps/backend/internal/agent/lifecycle/types.go +++ b/apps/backend/internal/agent/lifecycle/types.go @@ -27,13 +27,12 @@ type AgentExecution struct { WorkspacePath string // Path to the workspace (worktree or repository path) ACPSessionID string // ACP session ID to resume, if available AgentCommand string // Command to start the agent subprocess - Status v1.AgentStatus - StartedAt time.Time - FinishedAt *time.Time - ExitCode *int - ErrorMessage string - Progress int - Metadata map[string]interface{} + Status v1.AgentStatus + StartedAt time.Time + FinishedAt *time.Time + ExitCode *int + ErrorMessage string + Metadata map[string]interface{} // agentctl client for this execution agentctl *agentctl.Client diff --git a/apps/backend/internal/orchestrator/executor/executor.go b/apps/backend/internal/orchestrator/executor/executor.go index 9bf2048783..4cdfbf763e 100644 --- a/apps/backend/internal/orchestrator/executor/executor.go +++ b/apps/backend/internal/orchestrator/executor/executor.go @@ -112,7 +112,6 @@ type TaskExecution struct { AgentProfileID string StartedAt time.Time SessionState v1.TaskSessionState - Progress int LastUpdate time.Time // SessionID is the database ID of the agent session SessionID string @@ -129,7 +128,6 @@ func FromTaskSession(s *models.TaskSession) *TaskExecution { AgentProfileID: s.AgentProfileID, StartedAt: s.StartedAt, SessionState: agentSessionStateToV1(s.State), - Progress: s.Progress, LastUpdate: s.UpdatedAt, SessionID: s.ID, } @@ -308,7 +306,6 @@ func (e *Executor) ExecuteWithProfile(ctx context.Context, task *v1.Task, agentP RepositoryID: repositoryID, BaseBranch: baseBranch, State: models.TaskSessionStateCreated, - Progress: 0, StartedAt: now, UpdatedAt: now, AgentProfileSnapshot: agentProfileSnapshot, @@ -355,7 +352,6 @@ func (e *Executor) ExecuteWithProfile(ctx context.Context, task *v1.Task, agentP session.AgentExecutionID = resp.AgentExecutionID session.ContainerID = resp.ContainerID session.State = models.TaskSessionStateStarting - session.Progress = 0 session.ErrorMessage = "" session.UpdatedAt = time.Now().UTC() @@ -417,7 +413,6 @@ func (e *Executor) ExecuteWithProfile(ctx context.Context, task *v1.Task, agentP AgentProfileID: agentProfileID, StartedAt: now, SessionState: v1.TaskSessionStateStarting, - Progress: 0, LastUpdate: now, SessionID: sessionID, WorktreePath: resp.WorktreePath, @@ -584,7 +579,6 @@ func (e *Executor) ResumeSession(ctx context.Context, session *models.TaskSessio session.AgentExecutionID = resp.AgentExecutionID session.ContainerID = resp.ContainerID - session.Progress = 0 session.ErrorMessage = "" if startAgent { session.State = models.TaskSessionStateStarting @@ -665,7 +659,6 @@ func (e *Executor) ResumeSession(ctx context.Context, session *models.TaskSessio AgentProfileID: session.AgentProfileID, StartedAt: now, SessionState: v1.TaskSessionStateStarting, - Progress: 0, LastUpdate: now, SessionID: session.ID, WorktreePath: worktreePath, diff --git a/apps/backend/internal/task/dto/dto.go b/apps/backend/internal/task/dto/dto.go index 5192ea1c62..7a8a94b7af 100644 --- a/apps/backend/internal/task/dto/dto.go +++ b/apps/backend/internal/task/dto/dto.go @@ -135,7 +135,6 @@ type TaskSessionDTO struct { WorktreePath string `json:"worktree_path,omitempty"` WorktreeBranch string `json:"worktree_branch,omitempty"` State models.TaskSessionState `json:"state"` - Progress int `json:"progress"` ErrorMessage string `json:"error_message,omitempty"` Metadata map[string]interface{} `json:"metadata,omitempty"` AgentProfileSnapshot map[string]interface{} `json:"agent_profile_snapshot,omitempty"` @@ -408,7 +407,6 @@ func FromTaskSession(session *models.TaskSession) TaskSessionDTO { RepositoryID: session.RepositoryID, BaseBranch: session.BaseBranch, State: session.State, - Progress: session.Progress, ErrorMessage: session.ErrorMessage, Metadata: session.Metadata, AgentProfileSnapshot: session.AgentProfileSnapshot, diff --git a/apps/backend/internal/task/models/models.go b/apps/backend/internal/task/models/models.go index 4f43d5929b..114a6cc21b 100644 --- a/apps/backend/internal/task/models/models.go +++ b/apps/backend/internal/task/models/models.go @@ -203,7 +203,6 @@ type TaskSession struct { EnvironmentSnapshot map[string]interface{} `json:"environment_snapshot,omitempty"` RepositorySnapshot map[string]interface{} `json:"repository_snapshot,omitempty"` State TaskSessionState `json:"state"` - Progress int `json:"progress"` // 0-100 ErrorMessage string `json:"error_message,omitempty"` Metadata map[string]interface{} `json:"metadata,omitempty"` StartedAt time.Time `json:"started_at"` @@ -226,7 +225,6 @@ func (s *TaskSession) ToAPI() map[string]interface{} { "base_branch": s.BaseBranch, "worktrees": s.Worktrees, "state": string(s.State), - "progress": s.Progress, "started_at": s.StartedAt, "updated_at": s.UpdatedAt, } diff --git a/apps/backend/internal/task/repository/sqlite.go b/apps/backend/internal/task/repository/sqlite.go index 3f03f34be3..3d16ea3347 100644 --- a/apps/backend/internal/task/repository/sqlite.go +++ b/apps/backend/internal/task/repository/sqlite.go @@ -249,7 +249,6 @@ func (r *sqliteRepository) initSchema() error { environment_snapshot TEXT DEFAULT '{}', repository_snapshot TEXT DEFAULT '{}', state TEXT NOT NULL DEFAULT 'CREATED', - progress INTEGER DEFAULT 0, error_message TEXT DEFAULT '', metadata TEXT DEFAULT '{}', started_at DATETIME NOT NULL, @@ -1987,12 +1986,12 @@ func (r *sqliteRepository) CreateTaskSession(ctx context.Context, session *model id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at - ) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) + state, error_message, metadata, started_at, completed_at, updated_at + ) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) `, session.ID, session.TaskID, session.AgentExecutionID, session.ContainerID, session.AgentProfileID, session.ExecutorID, session.EnvironmentID, session.RepositoryID, session.BaseBranch, string(agentProfileSnapshotJSON), string(executorSnapshotJSON), string(environmentSnapshotJSON), string(repositorySnapshotJSON), - string(session.State), session.Progress, session.ErrorMessage, string(metadataJSON), + string(session.State), session.ErrorMessage, string(metadataJSON), session.StartedAt, session.CompletedAt, session.UpdatedAt) return err @@ -2013,14 +2012,14 @@ func (r *sqliteRepository) GetTaskSession(ctx context.Context, id string) (*mode SELECT id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at + state, error_message, metadata, started_at, completed_at, updated_at FROM task_sessions WHERE id = ? `, id).Scan( &session.ID, &session.TaskID, &session.AgentExecutionID, &session.ContainerID, &session.AgentProfileID, &session.ExecutorID, &session.EnvironmentID, &session.RepositoryID, &session.BaseBranch, &agentProfileSnapshotJSON, &executorSnapshotJSON, &environmentSnapshotJSON, &repositorySnapshotJSON, - &state, &session.Progress, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, + &state, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, ) if err == sql.ErrNoRows { @@ -2084,14 +2083,14 @@ func (r *sqliteRepository) GetTaskSessionByTaskID(ctx context.Context, taskID st SELECT id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at + state, error_message, metadata, started_at, completed_at, updated_at FROM task_sessions WHERE task_id = ? ORDER BY started_at DESC LIMIT 1 `, taskID).Scan( &session.ID, &session.TaskID, &session.AgentExecutionID, &session.ContainerID, &session.AgentProfileID, &session.ExecutorID, &session.EnvironmentID, &session.RepositoryID, &session.BaseBranch, &agentProfileSnapshotJSON, &executorSnapshotJSON, &environmentSnapshotJSON, &repositorySnapshotJSON, - &state, &session.Progress, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, + &state, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, ) if err == sql.ErrNoRows { @@ -2155,7 +2154,7 @@ func (r *sqliteRepository) GetActiveTaskSessionByTaskID(ctx context.Context, tas SELECT id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at + state, error_message, metadata, started_at, completed_at, updated_at FROM task_sessions WHERE task_id = ? AND state IN ('CREATED', 'STARTING', 'RUNNING', 'WAITING_FOR_INPUT') ORDER BY started_at DESC LIMIT 1 @@ -2164,7 +2163,7 @@ func (r *sqliteRepository) GetActiveTaskSessionByTaskID(ctx context.Context, tas &session.ExecutorID, &session.EnvironmentID, &session.RepositoryID, &session.BaseBranch, &agentProfileSnapshotJSON, &executorSnapshotJSON, &environmentSnapshotJSON, &repositorySnapshotJSON, - &state, &session.Progress, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, + &state, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, ) if err == sql.ErrNoRows { @@ -2243,12 +2242,12 @@ func (r *sqliteRepository) UpdateTaskSession(ctx context.Context, session *model agent_execution_id = ?, container_id = ?, agent_profile_id = ?, executor_id = ?, environment_id = ?, repository_id = ?, base_branch = ?, agent_profile_snapshot = ?, executor_snapshot = ?, environment_snapshot = ?, repository_snapshot = ?, - state = ?, progress = ?, error_message = ?, metadata = ?, completed_at = ?, updated_at = ? + state = ?, error_message = ?, metadata = ?, completed_at = ?, updated_at = ? WHERE id = ? `, session.AgentExecutionID, session.ContainerID, session.AgentProfileID, session.ExecutorID, session.EnvironmentID, session.RepositoryID, session.BaseBranch, string(agentProfileSnapshotJSON), string(executorSnapshotJSON), string(environmentSnapshotJSON), string(repositorySnapshotJSON), - string(session.State), session.Progress, session.ErrorMessage, string(metadataJSON), session.CompletedAt, + string(session.State), session.ErrorMessage, string(metadataJSON), session.CompletedAt, session.UpdatedAt, session.ID) if err != nil { return err @@ -2290,7 +2289,7 @@ func (r *sqliteRepository) ListTaskSessions(ctx context.Context, taskID string) SELECT id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at + state, error_message, metadata, started_at, completed_at, updated_at FROM task_sessions WHERE task_id = ? ORDER BY started_at DESC `, taskID) if err != nil { @@ -2318,7 +2317,7 @@ func (r *sqliteRepository) ListActiveTaskSessions(ctx context.Context) ([]*model SELECT id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at + state, error_message, metadata, started_at, completed_at, updated_at FROM task_sessions WHERE state IN ('CREATED', 'STARTING', 'RUNNING', 'WAITING_FOR_INPUT') ORDER BY started_at DESC `) if err != nil { @@ -2346,7 +2345,7 @@ func (r *sqliteRepository) ListActiveTaskSessionsByTaskID(ctx context.Context, t SELECT id, task_id, agent_execution_id, container_id, agent_profile_id, executor_id, environment_id, repository_id, base_branch, agent_profile_snapshot, executor_snapshot, environment_snapshot, repository_snapshot, - state, progress, error_message, metadata, started_at, completed_at, updated_at + state, error_message, metadata, started_at, completed_at, updated_at FROM task_sessions WHERE task_id = ? AND state IN ('CREATED', 'STARTING', 'RUNNING', 'WAITING_FOR_INPUT') ORDER BY started_at DESC `, taskID) if err != nil { @@ -2441,7 +2440,7 @@ func (r *sqliteRepository) scanTaskSessions(ctx context.Context, rows *sql.Rows) &session.ExecutorID, &session.EnvironmentID, &session.RepositoryID, &session.BaseBranch, &agentProfileSnapshotJSON, &executorSnapshotJSON, &environmentSnapshotJSON, &repositorySnapshotJSON, - &state, &session.Progress, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, + &state, &session.ErrorMessage, &metadataJSON, &session.StartedAt, &completedAt, &session.UpdatedAt, ) if err != nil { return nil, err diff --git a/apps/backend/internal/task/repository/sqlite_test.go b/apps/backend/internal/task/repository/sqlite_test.go index 81bd0f35d8..e2d61da929 100644 --- a/apps/backend/internal/task/repository/sqlite_test.go +++ b/apps/backend/internal/task/repository/sqlite_test.go @@ -784,7 +784,6 @@ func TestSQLiteRepository_TaskSessionCRUD(t *testing.T) { ExecutorID: "executor-1", EnvironmentID: "env-1", State: models.TaskSessionStateStarting, - Progress: 0, Metadata: map[string]interface{}{"key": "value"}, } if err := repo.CreateTaskSession(ctx, session); err != nil { @@ -820,7 +819,6 @@ func TestSQLiteRepository_TaskSessionCRUD(t *testing.T) { // Update agent session session.State = models.TaskSessionStateRunning - session.Progress = 50 if err := repo.UpdateTaskSession(ctx, session); err != nil { t.Fatalf("failed to update agent session: %v", err) } @@ -828,9 +826,6 @@ func TestSQLiteRepository_TaskSessionCRUD(t *testing.T) { if retrieved.State != models.TaskSessionStateRunning { t.Errorf("expected state 'running', got %s", retrieved.State) } - if retrieved.Progress != 50 { - t.Errorf("expected progress 50, got %d", retrieved.Progress) - } // Delete agent session if err := repo.DeleteTaskSession(ctx, session.ID); err != nil { diff --git a/apps/web/hooks/domains/session/use-session-resumption.ts b/apps/web/hooks/domains/session/use-session-resumption.ts index 0338aecab7..7a915b1d0e 100644 --- a/apps/web/hooks/domains/session/use-session-resumption.ts +++ b/apps/web/hooks/domains/session/use-session-resumption.ts @@ -91,7 +91,6 @@ export function useSessionResumption( id: sessionId, task_id: taskId, state: status.state as TaskSessionState, - progress: session?.progress ?? 0, started_at: session?.started_at ?? '', updated_at: session?.updated_at ?? '', }); @@ -125,7 +124,6 @@ export function useSessionResumption( id: sessionId, task_id: taskId, state: resumeResp.state as TaskSessionState, - progress: session?.progress ?? 0, started_at: session?.started_at ?? '', updated_at: session?.updated_at ?? '', }); @@ -185,7 +183,6 @@ export function useSessionResumption( id: sessionId, task_id: taskId, state: response.state as TaskSessionState, - progress: session?.progress ?? 0, started_at: session?.started_at ?? '', updated_at: session?.updated_at ?? '', }); diff --git a/apps/web/lib/types/http.ts b/apps/web/lib/types/http.ts index cd2a908630..d130799c60 100644 --- a/apps/web/lib/types/http.ts +++ b/apps/web/lib/types/http.ts @@ -146,7 +146,6 @@ export type TaskSession = { worktree_path?: string; worktree_branch?: string; state: TaskSessionState; - progress: number; error_message?: string; metadata?: Record | null; agent_profile_snapshot?: Record | null; diff --git a/apps/web/lib/ws/handlers/agent-session.ts b/apps/web/lib/ws/handlers/agent-session.ts index 2e9426c284..70e746ceec 100644 --- a/apps/web/lib/ws/handlers/agent-session.ts +++ b/apps/web/lib/ws/handlers/agent-session.ts @@ -31,7 +31,6 @@ export function registerTaskSessionHandlers(store: StoreApi): WsHandle id: sessionId, task_id: taskId, state: newState, - progress: 0, started_at: '', updated_at: '', ...(agentProfileId ? { agent_profile_id: agentProfileId } : {}), @@ -47,7 +46,6 @@ export function registerTaskSessionHandlers(store: StoreApi): WsHandle id: sessionId, task_id: taskId, state: newState, - progress: 0, started_at: '', updated_at: '', ...(agentProfileId ? { agent_profile_id: agentProfileId } : {}),