Commit graph

945 commits

Author SHA1 Message Date
Bryan Helmkamp
4ac4fc4ea9 Add GitHub App manifest setup to arc install
Adds a temporary local HTTP server in `arc install` that handles the
GitHub App manifest registration flow, enabling standalone users to
register a GitHub App without running the arc-web server.

Also gates server-only install steps (pre-flight checks, server.toml,
secrets/certs, start servers) behind #[cfg(feature = "server")] and
removes the `gh` CLI from system dependency checks. Reloads .env before
running arc doctor so it picks up freshly written credentials.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:36:13 -04:00
Bryan Helmkamp
d80335e0fc Add 2026-03-10 changelog and update docs for new CLI commands
Changelog: MCP servers in workflows, arc init, arc diff.
Docs: arc init, arc diff, arc ssh, arc preview, arc doctor --dry-run,
cli.log per-run tracing, pull_request precedence, SSH/preview pages.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:25:42 -04:00
Bryan Helmkamp
6db8fd317b Use GitHub-hosted runners for release workflow
Self-hosted runner lacks credentials for HTTPS checkout.
Switch both compile (Linux) and release jobs to ubuntu-latest.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:23:05 -04:00
Bryan Helmkamp
cbe6282263 Flip arc doctor default to live mode with --dry-run opt-out
Live service probes now run by default instead of requiring --live.
Added --dry-run flag to skip probes when needed. Install command now
runs doctor with live probes to validate setup.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:17:59 -04:00
Bryan Helmkamp
e06eb6fdd4 Trigger CI
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:10:46 -04:00
Bryan Helmkamp
78fb243447 Remove CARGO_INCREMENTAL (conflicts with sccache)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:08:58 -04:00
Bryan Helmkamp
4a63650fe3 Add cargo bin to PATH for self-hosted runners
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:07:30 -04:00
Bryan Helmkamp
3755f6fd8a Remove CARGO_INCREMENTAL from clippy (conflicts with sccache), keep for test
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:05:30 -04:00
Bryan Helmkamp
a4eb6fce06 Optimize CI for self-hosted runners and make macOS tests on-demand only
Remove rust-toolchain/rust-cache setup (pre-installed on self-hosted),
disable checkout clean, enable sccache and incremental compilation.
Split macOS tests into a separate job that only runs on workflow_dispatch
since release.yml already gates on macOS tests.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 14:03:45 -04:00
Bryan Helmkamp
aad4cb61c0 Skip mTLS tests on macOS (LibreSSL generates incompatible certs)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:55:29 -04:00
Bryan Helmkamp
c3df0d380a Run clippy only on Linux, not macOS
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:53:43 -04:00
Bryan Helmkamp
076bebe218 Switch Linux CI jobs from ubuntu-latest to self-hosted
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:50:12 -04:00
Bryan Helmkamp
89655140f8 Show Arc Details in PR body even without retro
Extend conclusion.json with per-stage operational data (cost, duration,
retries) so the Arc Details section of PR descriptions no longer depends
on retro.json. The retro section remains optional and only appears when
the retro agent runs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:49:17 -04:00
Bryan Helmkamp
2d31aae9a0 Add release workflow and improve CI pipelines
- Add release.yml: tag-triggered (v*) workflow that cross-compiles
  for aarch64-apple-darwin and x86_64-unknown-linux-gnu, packages
  archives with SHA256 checksums, and creates a GitHub Release
- Add workflow_dispatch, concurrency groups, and cache-on-failure
  to rust.yml and typescript.yml
- Run clippy and test on both ubuntu-latest and macos-15
- Add release profile with thin LTO and strip to Cargo.toml

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:40:29 -04:00
Bryan Helmkamp
4558774a34 Add [pull_request] support to project config (arc.toml)
Project-level arc.toml can now set [pull_request] with enabled/draft
fields, slotting between cli.toml defaults and workflow.toml overrides.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:34:26 -04:00
Bryan Helmkamp
2969c98057 Add CliConfig helper methods to reduce accessor boilerplate
Add app_id(), slug(), and git_author() methods to CliConfig to
replace repeated .git.as_ref().and_then(...) chains across 5 call
sites in main.rs and doctor.rs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:21:06 -04:00
Bryan Helmkamp
c32e74fbb4 Make standalone CLI read only cli.toml, never server.toml
Move GitHub App credentials (app_id, slug) and run defaults (llm,
sandbox, pull_request) into cli.toml so standalone commands (run, pr
create, llm) no longer require server.toml. The server.toml loading is
now limited to `arc serve` and server-mode doctor checks.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:12:30 -04:00
Bryan Helmkamp
20b446d1e5 Add comments and docs link to generated arc.toml
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:02:59 -04:00
Bryan Helmkamp
8cec8d6546 Add arc init command to initialize a new arc project
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 13:00:36 -04:00
Bryan Helmkamp
44731e0926 Rename arc setup to arc install for clarity
The one-time environment setup command (LLMs, certs, GitHub) is now
`arc install`, freeing up naming space for a future `arc init` command
for per-project initialization.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 12:56:53 -04:00
Bryan Helmkamp
5f9c211031 Add arc diff command to view workflow run diffs
Surfaces existing final.patch and per-node diff.patch files via CLI.
Supports live diffs from in-progress runs by reconnecting to the sandbox.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 12:50:51 -04:00
Bryan Helmkamp
af4cad399b Fix Rust CI by switching from larger runners to standard runners
ubuntu-latest-16-cores requires a GitHub Team/Enterprise org plan and
was causing all jobs to stay queued indefinitely.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 12:48:15 -04:00
Bryan Helmkamp
fb04333d45 Fix LLM provider resolution to use model catalog before default fallback
When no explicit provider is set on a request, resolve_provider now
consults the model catalog (e.g. gpt-5.4 → openai) before falling back
to the client's default provider. This fixes PR description generation
sending cross-provider model IDs to the wrong provider.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 12:47:24 -04:00
Bryan Helmkamp
4fe05e8a71 Add arc ssh command for SSH access to Daytona sandboxes
Standalone subcommand that creates SSH credentials for a run's Daytona
sandbox and connects directly (or prints the command with --print).
Also parameterizes create_ssh_access TTL instead of hardcoding 60 min.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 12:28:17 -04:00
Bryan Helmkamp
f27a5e187a Fix verbose mode breaking terminal rendering after many tool calls
In verbose mode, completed tool call bars accumulated in indicatif's
MultiProgress without limit. After ~80+ bars exceeded the terminal
height, indicatif's cursor repositioning broke and all rendering stopped.

Now in verbose mode, completed tool calls are printed as permanent output
via multi.println() and their bars are removed from MultiProgress. Only
running tool calls remain as live bars with spinner + elapsed time. This
keeps MultiProgress small regardless of how many tool calls execute.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 11:58:07 -04:00
Bryan Helmkamp
ec7fc8d5a2 Add arc preview command for Daytona sandbox preview URLs
Provides CLI access to preview URLs for ports exposed by Daytona sandboxes.
Supports standard (URL + token + curl), signed (self-contained URL), and
--open (browser launch) modes.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 11:55:47 -04:00
Bryan Helmkamp
98de349f20 Add vnc test 2026-03-10 11:32:09 -04:00
Bryan Helmkamp
9644e2614e Add golden-gate demo 2026-03-10 11:32:02 -04:00
Bryan Helmkamp
7e441145be Remove pre-specified image from imagegen-openai 2026-03-10 11:31:47 -04:00
Bryan Helmkamp
74a0b89ca1 Fix imagegen script dying before error handling on API failures
Remove --fail-with-body from curl so the response body (including error
JSON) is always captured. Previously, set -e killed the script at the
curl line on non-2xx responses before the error-checking code could run,
leaving the agent with an opaque exit code 22 and no actionable message.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 10:24:13 -04:00
Bryan Helmkamp
ad8a91388d Switch imagegen to OpenAI gpt-image-1 and add imagegen-openai demo
Replace Gemini API with OpenAI /v1/images/generations endpoint in the
imagegen script. Remove unsupported response_format parameter (gpt-image-1
returns b64_json by default). Add standalone imagegen-openai workflow for
testing image generation independently.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 10:22:44 -04:00
Bryan Helmkamp
1dcad0529a Split ~/.arc/logs/ into logs/ and runs/
Per-run data now lives in ~/.arc/runs/ while daily CLI log files
stay in ~/.arc/logs/. Renames: logs_root → run_dir (RunConfig field,
Handler trait param, all handlers), logs_dir → run_dir (CLI arg,
local variables), default_logs_base → default_runs_base (path fn).
Adds DB migration 002 to rename workflow_runs.logs_dir → run_dir.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 09:40:03 -04:00
Bryan Helmkamp
54ecae9586 Write per-run tracing logs to cli.log inside each run directory
Adds a switchable tracing layer that writes to ~/.arc/logs/{run-dir}/cli.log,
so all diagnostic info for a run is co-located with its other artifacts instead
of buried in the shared daily log file.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 09:30:00 -04:00
Bryan Helmkamp
ae5bdd4446 Hide arc ps subcommand from help output
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 09:22:19 -04:00
Bryan Helmkamp
9ae9e7b0b6 Simplify imagegen workflow 2026-03-10 09:18:01 -04:00
Bryan Helmkamp
53e218926f Print full ~/... paths for assets instead of sandbox-relative paths
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 09:14:24 -04:00
Bryan Helmkamp
1263637211 Replace install_playwright command node with Playwright MCP server
The Playwright MCP server provides a browser_install tool, so we can
drop the separate command node and let the agent install the browser
via MCP instead.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 09:02:55 -04:00
Bryan Helmkamp
5883b71efd Print captured asset paths after workflow run output
Display collected assets in an "=== Assets ===" section after the run
result, so users can see which files were captured without digging
through the logs directory.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 09:01:52 -04:00
Bryan Helmkamp
1552ea4380 Fix playwright install command in web-game-demo workflow
Use npx directly instead of npm install, which fails due to the repo's
workspace:* protocol in package.json.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:56:25 -04:00
Bryan Helmkamp
5515c11aad Add GitHub App check to arc doctor for all builds, validate private key
The GitHub App check was gated behind #[cfg(feature = "server")] so it
never ran in CLI-only builds. It also only checked whether env vars were
set, not whether the key could actually sign JWTs.

- Move GithubAppStatus and check_github_app out of the server feature gate
- Try sign_app_jwt to validate the private key, catching corrupt keys
- Show app_id and slug in doctor output
- Keep server-only fields (client_id, client_secret, webhook_secret)
  behind #[cfg(feature = "server")]

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:55:14 -04:00
Bryan Helmkamp
9feb2c699b Add develop-web-game skill and verification workflow
Port the OpenAI Codex develop-web-game skill (Playwright-based game dev
loop) into skills/develop-web-game/ with paths adapted for Arc's
workspace-relative skill discovery. Add a web-game-demo workflow that
verifies the skill and its asset files (playwright client script,
action payloads JSON) are properly discovered and accessible in a
Daytona sandbox.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:41:12 -04:00
Bryan Helmkamp
03ac5bc6ac Hide llm, exec, and parse commands from CLI help output
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:25:49 -04:00
Bryan Helmkamp
ea73e40070 Gate server-only doctor checks behind #[cfg(feature = "server")]
Arc API, Arc Web, GitHub App, and cryptographic key checks are only
relevant when the server feature is enabled. Without this gate, `arc
doctor` showed misleading connectivity errors for services that cannot
even be started.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:23:48 -04:00
Bryan Helmkamp
3a7f5cdb6c Fix unused_assignments warning in run_from_branch
Return worktree_path from the match expression instead of mutating
a pre-initialized variable.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:20:24 -04:00
Bryan Helmkamp
7a18faa712 Fall back to localhost for sandbox MCP transport on local sandboxes
When the sandbox does not support preview URLs (e.g., local sandbox),
fall back to http://localhost:{port} instead of erroring. This makes
the sandbox MCP transport work transparently on both local and remote
(Daytona) sandboxes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 08:14:37 -04:00
Bryan Helmkamp
2079677e50 Move standalone vs. server mode content to Note callout at top of quick start
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:13:46 -04:00
Bryan Helmkamp
ca124638ae Document MCP sandbox transport and workflow-level MCP configuration
- docs/agents/mcp.mdx: Remove pre-release warning. Add sandbox transport
  docs alongside stdio and HTTP. Restructure configuration section to
  cover both cli.toml and run config TOML. Replace filesystem example
  with Playwright browser automation example.
- docs/execution/run-configuration.mdx: Add [mcp_servers] section with
  field reference for all three transport types. Add to full example.
- docs/reference/cli-configuration.mdx: Add sandbox transport subsection.
  Cross-reference workflow-level MCP config.
- docs/integrations/daytona.mdx: Add MCP sandbox transport to feature table.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 08:10:05 -04:00
Bryan Helmkamp
878eccb58e Add Status column and Sprites provider to environments docs
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-10 08:09:52 -04:00
Bryan Helmkamp
08461fe603 Add MCP server support to workflow engine and Playwright demo workflow
Wire MCP server configs from workflow TOML into agent sessions so
MCP tools are available to agent stages during workflow runs.

Changes:
- run_config.rs: add mcp_servers HashMap to WorkflowRunConfig
- backend.rs: AgentApiBackend.with_mcp_servers() passes configs to SessionConfig
- run.rs: extract mcp_servers from RunConfig and pass to backend
- demo/mod.rs: add default mcp_servers field to struct literals

New workflow: arc/workflows/playwright-demo/
- Runs on Daytona with daytona-medium snapshot
- Configures Playwright MCP as a sandbox transport (port 3100)
- Agent browses Hacker News, takes screenshots at each step
- asset_globs captures screenshots/** into logs directory

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 08:05:12 -04:00
Bryan Helmkamp
d426eebf1a Add sandbox MCP transport for running MCP servers inside Daytona sandboxes
Adds McpTransport::Sandbox variant that starts an MCP server inside the
sandbox, waits for it to listen, gets a Daytona preview URL, and rewrites
to HTTP transport for the MCP client connection.

Key changes:
- Sandbox trait: add get_preview_url(port) for authenticated port access
- DaytonaSandbox: implement get_preview_url via Daytona SDK preview links
- McpTransport::Sandbox: new variant with command, port, env fields
- Session: resolve_sandbox_mcp_servers() starts servers and rewrites to HTTP
- Integration test: end-to-end Playwright MCP in Daytona - navigates to
  example.com and verifies "Example Domain" in accessibility snapshot

Config example:
  [mcp_servers.playwright]
  type = "sandbox"
  command = ["npx", "@playwright/mcp@latest", "--port", "3100", "--headless"]
  port = 3100

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 02:09:04 -04:00