[DO NOT MERGE][Feature] Support stateful infra(AGS/etc.)#26
Open
RealAlexandreAI wants to merge 33 commits into
Open
[DO NOT MERGE][Feature] Support stateful infra(AGS/etc.)#26RealAlexandreAI wants to merge 33 commits into
RealAlexandreAI wants to merge 33 commits into
Conversation
Capture architecture, lifecycle, merge, and cherry-pick guidance before implementing stateful sandbox on main without the SCF dual-backend switch. Co-authored-by: Cursor <cursoragent@cursor.com>
Remove docs/stateful-infra-handoff.md; planning docs live under .plans/ only (gitignored per project convention). Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Replace SCF/legacy AGS paths with stateful gateway + TRW tool-override. Add preview-url SSE, OVC preview proxy (strip gzip Content-Encoding), and faster task polling so coding preview loads without waiting for stream end. Co-authored-by: Cursor <cursoragent@cursor.com>
…ipts Add buildGatewayTarget/gatewayFetch for E2b-Sandbox-Port routing, CLI to describe/probe ports, and update-stateful-tool-ports (adds 5173). New tools from ensure-stateful-tool include vite/ttyd ports. Co-authored-by: Cursor <cursoragent@cursor.com>
Add 10s×6 polling after tool create and on retryable StartSandboxInstance failures so users see template_create/template_warmup instead of opaque InternalError stalls. Format AGS errors with RequestId for support, and add debug-start-instance script for operator repro. Co-authored-by: Cursor <cursoragent@cursor.com>
Ignore packages/server/*.db from local dev, remove ad-hoc CodeBuddy probe scripts, and apply Prettier to sandbox modules left dirty after the prior commit hook. Co-authored-by: Cursor <cursoragent@cursor.com>
Sync upstream env-pool, agent SSE/tool-confirm fixes, opencode model catalog, and docs. Resolve conflicts keeping stateful TRW paths (/api/workspace/env, provider.createMcpClient, preview/5173) and AGENT_DEBUG_JSONL-gated local debug logs. Co-authored-by: Cursor <cursoragent@cursor.com>
Replace stale SCF/Scope API narrative in architecture, README, and setup; emit STATEFUL_* in init.mjs. Restore main task-sidebar delete UX and drop unrelated LoginPage registration copy from the stateful branch. Co-authored-by: Cursor <cursoragent@cursor.com>
- Resolve Tool by ovc-{envId} without STATEFUL_TOOL_ID; bind/create progress phases
- Distinguish shared vs isolated instance reuse in provider and status UI
- Default STATEFUL_SANDBOX_IMAGE from team public TCR; optional tenant TCR via setup:tcr
- Document sandbox infra (not product codename), provision vs instance mode
- Dockerfile git for install-skills; lockfile sync; setup-tcr syncs server .env image
Co-authored-by: Cursor <cursoragent@cursor.com>
Expose TerminalRef from the terminal tab and add toolbar actions; use a stub terminal placeholder until ttyd preview is wired again. Co-authored-by: Cursor <cursoragent@cursor.com>
Inject git archive via workspace/env after instance start (avoid boot-time probe failures). Reconcile tool image without dropping Ports/Probe; improve shared-instance progress and file browser. Add TRW miniprogram client and API alignment docs. Co-authored-by: Cursor <cursoragent@cursor.com>
Restore ttyd terminal, simplify env templates, document workspace/env git injection and branch vs upstream. Add deploy.mjs, cloudrun-deploy.md, and @cloudbase/manager-node for pnpm deploy:cloud. Co-authored-by: Cursor <cursoragent@cursor.com>
Merge latest upstream (English README, deploy:cloud, admin scripts, auth tweaks). Keep feature/stateful-infra: AGS/TRW sandbox, TCB_API_KEY gate, TRW preview/vite paths; drop SCF sandbox manager and container-probe. Update README-zh and docs for stateful + CloudRun. Co-authored-by: Cursor <cursoragent@cursor.com>
Jotai task atom setter accepts Partial<FileBrowserState>, not a React-style updater function — fixes Docker/web build TS2560. Co-authored-by: Cursor <cursoragent@cursor.com>
Add ENABLE_AUTH_MODE (default false) with required TCB_ACCESS_TOKEN when enabled: omit StartSandboxInstance AuthMode NONE, attach X-Access-Token on data-plane requests, and inject ENABLE_AUTH_MODE into workspace env only. Align docs and env templates (setup, .env.example, init), restore main OpenCode e2e scripts as SCF-legacy, remove obsolete trw-api-alignment doc, and rename TRW/OVC references to sandbox business image terminology. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Split turn progress into a latched sandbox row (reuse/start/fail) and a separate LLM row so ready sandboxes no longer masquerade as model streaming. Add DELETE /api/tasks?action=all with shared-mode instance stop, SANDBOX_TTL_SECONDS for AGS timeouts, default WORKSPACE_ISOLATION=shared, and sidebar tooltips. Co-authored-by: Cursor <cursoragent@cursor.com>
Route virtual port 7681 through TRW gateway preview with correct WS handshake (tty protocol, binary frames, gateway path). Limit AGS tool ports to 9000/49983, add terminal-health, and improve Logs terminal UX with sandbox progress messages in the task stream. Co-authored-by: Cursor <cursoragent@cursor.com>
Batch soft-delete with configurable concurrency; shared mode stops one sandbox instance; isolated destroys run in background. Optimistic sidebar clear with revert on failure. Restore probe-gateway-port ops script. Co-authored-by: Cursor <cursoragent@cursor.com>
Use appJotaiStore with JotaiProvider so sidebar loads real tasks instead of stuck skeletons. Centralize list state in task-list-store with optimistic clear on delete-all and stale-fetch guards. Stream logs to UI immediately, stabilize terminal probe against refresh loops, and align tasks API listing. Co-authored-by: Cursor <cursoragent@cursor.com>
Move secrets to root .env.local (dev) and .env.cloud (deploy), remove packages/server/.env.example, and update init/deploy/setup scripts accordingly. Add masked secret prompts via @inquirer/password and default CodeBuddy custom models to off in init. Co-authored-by: Cursor <cursoragent@cursor.com>
Remove stale layout/AppLayout and a redundant phase check that failed tsc. Let cloud init use an ASK_USER_BASE_URL placeholder and write it back on deploy. Co-authored-by: Cursor <cursoragent@cursor.com>
Document split env workflow in README; deploy script prints console link early, streams CLI with heartbeats, polls CloudRun status, and writes back sh.run URLs. Co-authored-by: Cursor <cursoragent@cursor.com>
Centralize CloudService loading via lib/utils/index.js to fix ERR_UNSUPPORTED_DIR_IMPORT when creating sandboxes on CloudRun Node 22. Co-authored-by: Cursor <cursoragent@cursor.com>
Register CloudBase MCP policies statically in bundled dist, route git archive vars through workspace/init only, parse mcporter schema without stderr pollution, and log upstream WS upgrade HTTP status for terminal debug. Co-authored-by: Cursor <cursoragent@cursor.com>
Gateway returned 403 on WS upgrade when OVC forwarded CloudRun Origin to tcloudbasegateway; upstream now sends sandbox auth headers only. Co-authored-by: Cursor <cursoragent@cursor.com>
Keep Stateful sandbox flow (TCB_API_KEY, .env.local/.env.cloud, preview-ws-proxy). Bring in main: OpenCode dep, TCR enterprise + podman, coding-mode tool auto-allow, community docs; drop scf-sandbox-manager (stateful path only). Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
支持更多 infra