Skip to content

feat(sandbox,ca): leave experimental, one create and ssh output for sandboxes and cloud agents - #1371

Merged
codyde merged 5 commits into
masterfrom
feat/sandbox-agent-consistent-output
Nov 17, 2026
Merged

codyde merged 5 commits into
masterfrom
feat/sandbox-agent-consistent-output

Conversation

@codyde

@codyde codyde commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

Sandboxes and cloud agents leave experimental. This drops the warning banners and gives both the same create and ssh output, since a cloud agent is a sandbox with agent tooling on top.

Changes

  • Remove the "experimental and APIs may change" banner from railway sandbox, railway code and the railway ca launcher.
  • Cloud agents are GA: drop the CLOUD_AGENTS Priority Boarding preflight (access.rs, the CloudAgentAccess query, the flag_missing event, "Requires Cloud Agents access" in help and docs).
  • sandbox create and ca create print one block from a shared renderer (commands/output/machine.rs): header, Status, Region, Idle, Domains, then a Connect line. The agent adds one dim hint line.
  • sandbox create and sandbox fork wait until running (5 min, the SDK's READINESS_TIMEOUT_MS) and fail clearly on FAILED or a destroyed sandbox. --no-wait returns at once and prints the same block with the current status.
  • JSON is additive: sandboxes gain name (null) and projectId; cloud agents gain region and domains (new CloudAgentPlacement query, region added to CloudAgent in schema.json).
  • sandbox ssh and ca ssh show a "Connecting to ..." spinner ("Waking cloud agent ..." when asleep) and one Disconnected from ... line after an interactive session. One-off ssh -- <cmd> prints nothing extra in either, so ca ssh -- <cmd> drops its disconnect note.
  • The create block hides the agent's harness gate domain (port 8790); --json keeps it.
  • Drop "Requires Sandboxes access." from railway sandbox --help: sandboxes have no feature flag and are allowed on every plan.

Before / after

railway sandbox create --private-network --domain web:3000

# before (returned while CREATING)
✓ Created sandbox 4f9d2c1e-7b3a-4c8e-9a51-2d6f0b8e3c47 (now active)
  status: CREATING
  region: us-west2
  idle timeout: 10m
  domains: publishing (run `railway sandbox list` to see the URLs)

Connect with:
  railway sandbox ssh

# after (waits until running)
✓ Created sandbox 4f9d2c1e-7b3a-4c8e-9a51-2d6f0b8e3c47
  Status:   Running
  Region:   us-west2
  Idle:     Destroyed after 10 min idle
  Domains:  https://web-8f2a.up.railway.app -> port 3000

Connect: railway sandbox ssh

# after, --no-wait
✓ Created sandbox 4f9d2c1e-7b3a-4c8e-9a51-2d6f0b8e3c47
  Status:   Creating
  Region:   us-west2
  Idle:     Destroyed after 10 min idle
  Domains:  Publishing (`railway sandbox list` shows the URLs)

Connect: railway sandbox ssh

railway ca create my-box

# before (#1369)
✓ Created agent my-box (running)

It has no coding agent on it yet — railway ca ssh my-box installs one and drops you in.
An idle agent sleeps after 5 minutes, which ends its processes, and wakes when you connect. `railway ca sleep my-box` sleeps it now, `railway ca delete my-box` takes the disk with it.

# after
✓ Created cloud agent my-box
  Status:   Running
  Region:   us-east4
  Idle:     Sleeps after 5 min idle
  Domains:  https://app-3c9e1f.up.railway.app -> port 8080

Connect: railway ca ssh my-box
No coding agent is installed yet. `railway ca ssh my-box --session` sets one up.

Disconnect lines

# railway sandbox ssh, before: nothing
# after
Disconnected from sandbox <id>. It's destroyed after 10 min idle. `railway sandbox destroy` removes it now.
Disconnected from sandbox <id>. It keeps running until you destroy it with `railway sandbox destroy`.

# railway ca ssh, before (#1369)
Disconnected — agent my-box sleeps after 5 minutes with no SSH client, network traffic or agent turn, which ends its processes.
Disconnected — agent my-box is still running. `railway ca sleep my-box` stops the compute bill.
# after (agents created since 2026-10-08 00:37 UTC, then older ones)
Disconnected from cloud agent my-box. It sleeps after 5 minutes with no SSH client, network traffic or agent turn, which ends its processes. `railway ca sleep my-box` sleeps it now.
Disconnected from cloud agent my-box. It keeps running until you sleep it with `railway ca sleep my-box`.

Notes

  • railway sandbox create now waits until running; use --no-wait for the old behavior. The docs say create returns while CREATING (railwayapp/docs #1453) and need a one-line update once this releases.
  • Older CLIs keep working because the backend reports CLOUD_AGENTS for everyone (monorepo PR, link to follow).
  • The hint says railway ca ssh <name> --session rather than fix(ca,sandbox): idle-sleep copy, retire --base-image-digest #1369's railway ca ssh <name>: a plain ca ssh opens a login shell and installs nothing; --session starts the default harness.
  • Not changed here: railway code, the TUI and herdr keep their own create and "Session ended" messages, and ca wake still says "agent".
  • Verification: cargo fmt --check, build, test (1966 unit passed, 6 ignored; integration 6, 5, 10, 5, 4 passed), clippy --all-targets --all-features: 79/82 warnings, same as the base branch.

🤖 Generated with Claude Code

@codyde codyde added the release/minor Author minor release label Nov 17, 2026
Base automatically changed from fix/ca-idle-sleep-copy-and-template-digest to master November 17, 2026 19:23
codyde and others added 5 commits November 17, 2026 11:24
Sandboxes and cloud agents are leaving experimental, so `railway sandbox`,
`railway code` and the `railway ca` launcher no longer print the
"experimental and APIs may change" banner.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Cloud agents no longer sit behind the CLOUD_AGENTS flag, so `railway ca`,
`railway code`, `ca desktop` and the Codex/OpenCode clients stop asking for
the account's feature flags before launching. This removes the access module,
the CloudAgentAccess query, the flag_missing telemetry event and the
"Requires Cloud Agents access" lines in help and docs.

Older CLIs that still run the preflight keep working because the backend
reports CLOUD_AGENTS for every user.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A cloud agent is a sandbox with agent tooling on top, so `railway sandbox
create` and `railway ca create` now print the same block from one renderer
(commands/output/machine.rs): a "Created sandbox|cloud agent <label>" header,
aligned Status, Region, Idle and Domains fields, then one Connect line. The
agent adds a single dim line about installing a coding agent.

`railway sandbox create` (and `fork`) now waits until the sandbox runs, with
the SDK's 5 minute readiness timeout, and fails clearly on FAILED or a
destroyed sandbox. `--no-wait` keeps the old return-while-CREATING behavior
and prints the same block with the current status.

JSON is additive: sandbox output gains `name` (null; sandboxes have none) and
`projectId`; cloud agent output gains `region` and `domains`, read with a new
CloudAgentPlacement query. `region` is added to CloudAgent in schema.json.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
`railway sandbox ssh` and `railway ca ssh` now show a short "Connecting to
sandbox|cloud agent <label>" spinner (cloud agents: "Waking" when asleep) that
clears before ssh takes the terminal, and one line after an interactive
session:

  Disconnected from <kind> <label>. <what happens next>. <command to act now>.

Sandboxes say when they are destroyed (or that they never idle out); cloud
agents keep the idle-sleep wording and the old-agent split from
ca::sleeps_when_idle. One-off commands (`ssh -- <cmd>`) print nothing extra in
either, so `ca ssh -- <cmd>` no longer prints the disconnect note. Exit codes
are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
`railway sandbox --help` ended with "Requires Sandboxes access.", but
sandboxes have no feature flag and Backboard allows them on Free, Trial and
paid plans.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codyde
codyde force-pushed the feat/sandbox-agent-consistent-output branch from 13e73cd to 1175cae Compare November 17, 2026 19:28
@codyde
codyde merged commit 8dd9e79 into master Nov 17, 2026
8 checks passed
@codyde
codyde deleted the feat/sandbox-agent-consistent-output branch November 17, 2026 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release/minor Author minor release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant