mirror of
https://github.com/harivansh-afk/sandbox-agent.git
synced 2026-04-17 20:05:09 +00:00
Add header status pill showing task/session/sandbox state
Surface aggregate status (error, provisioning, running, ready, no sandbox) as a colored pill in the transcript panel header. Integrates task runtime status, session status, and sandbox availability via the sandboxProcesses interest topic so the pill accurately reflects unreachable sandboxes. Includes mock tasks demonstrating error, provisioning, and running states, unit tests for deriveHeaderStatus, and workspace-dashboard integration. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
098b8113f3
commit
5bd85e4a28
77 changed files with 2329 additions and 4134 deletions
|
|
@ -1,3 +1,5 @@
|
|||
import type { WorkbenchModelId } from "./workbench.js";
|
||||
|
||||
export type FoundryBillingPlanId = "free" | "team";
|
||||
export type FoundryBillingStatus = "active" | "trialing" | "past_due" | "scheduled_cancel";
|
||||
export type FoundryGithubInstallationStatus = "connected" | "install_required" | "reconnect_required";
|
||||
|
|
@ -55,7 +57,7 @@ export interface FoundryOrganizationSettings {
|
|||
slug: string;
|
||||
primaryDomain: string;
|
||||
seatAccrualMode: "first_prompt";
|
||||
defaultModel: "claude-sonnet-4" | "claude-opus-4" | "gpt-4o" | "o3";
|
||||
defaultModel: WorkbenchModelId;
|
||||
autoImportRepos: boolean;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -43,19 +43,17 @@ export const ConfigSchema = z.object({
|
|||
.object({
|
||||
local: z
|
||||
.object({
|
||||
rootDir: z.string().optional(),
|
||||
sandboxAgentPort: z.number().int().min(1).max(65535).optional(),
|
||||
image: z.string().optional(),
|
||||
})
|
||||
.default({}),
|
||||
daytona: z
|
||||
e2b: z
|
||||
.object({
|
||||
endpoint: z.string().optional(),
|
||||
apiKey: z.string().optional(),
|
||||
image: z.string().default("ubuntu:24.04"),
|
||||
template: z.string().optional(),
|
||||
})
|
||||
.default({ image: "ubuntu:24.04" }),
|
||||
.default({}),
|
||||
})
|
||||
.default({ local: {}, daytona: { image: "ubuntu:24.04" } }),
|
||||
.default({ local: {}, e2b: {} }),
|
||||
});
|
||||
|
||||
export type AppConfig = z.infer<typeof ConfigSchema>;
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ export const WorkspaceIdSchema = z
|
|||
.regex(/^[a-zA-Z0-9._-]+$/);
|
||||
export type WorkspaceId = z.infer<typeof WorkspaceIdSchema>;
|
||||
|
||||
export const ProviderIdSchema = z.enum(["daytona", "local"]);
|
||||
export const ProviderIdSchema = z.enum(["e2b", "local"]);
|
||||
export type ProviderId = z.infer<typeof ProviderIdSchema>;
|
||||
|
||||
export const AgentTypeSchema = z.enum(["claude", "codex"]);
|
||||
|
|
@ -24,12 +24,6 @@ export const TaskStatusSchema = z.enum([
|
|||
"init_enqueue_provision",
|
||||
"init_ensure_name",
|
||||
"init_assert_name",
|
||||
"init_create_sandbox",
|
||||
"init_ensure_agent",
|
||||
"init_start_sandbox_instance",
|
||||
"init_create_session",
|
||||
"init_write_db",
|
||||
"init_start_status_sync",
|
||||
"init_complete",
|
||||
"running",
|
||||
"idle",
|
||||
|
|
|
|||
|
|
@ -2,7 +2,15 @@ import type { AgentType, ProviderId, TaskStatus } from "./contracts.js";
|
|||
|
||||
export type WorkbenchTaskStatus = TaskStatus | "new";
|
||||
export type WorkbenchAgentKind = "Claude" | "Codex" | "Cursor";
|
||||
export type WorkbenchModelId = "claude-sonnet-4" | "claude-opus-4" | "gpt-4o" | "o3";
|
||||
export type WorkbenchModelId =
|
||||
| "claude-sonnet-4"
|
||||
| "claude-opus-4"
|
||||
| "gpt-5.3-codex"
|
||||
| "gpt-5.4"
|
||||
| "gpt-5.2-codex"
|
||||
| "gpt-5.1-codex-max"
|
||||
| "gpt-5.2"
|
||||
| "gpt-5.1-codex-mini";
|
||||
export type WorkbenchSessionStatus = "pending_provision" | "pending_session_create" | "ready" | "running" | "idle" | "error";
|
||||
|
||||
export interface WorkbenchTranscriptEvent {
|
||||
|
|
|
|||
|
|
@ -15,7 +15,8 @@ const cfg: AppConfig = ConfigSchema.parse({
|
|||
backup_retention_days: 7,
|
||||
},
|
||||
providers: {
|
||||
daytona: { image: "ubuntu:24.04" },
|
||||
local: {},
|
||||
e2b: {},
|
||||
},
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue