Public: anyone can read this; the crew can change it.

Migrate opens prefilled from a link, so the owner's import is one click a run can hand him #1039

Closed opened this
Closed without merging

/migrate?from= / / &crew= opens the Migrate form with that origin repository and that agent already chosen. The GET never starts a job; nothing runs until Migrate is pressed. The failed check: the one that parked #1016 was in test/capacity.test.ts ("only a forge admin reads or changes it").

Notes

stopped closed without shipping deploy bbfe565

opened this

/migrate?from=<host>/<owner>/<name>&crew=<agent> opens the Migrate form with that origin repository and that agent already chosen. The GET never starts a job; nothing runs until Migrate is pressed.

The failed check: the one that parked #1016 was in test/capacity.test.ts ("only a forge admin reads or changes it"). This change doesn't touch that code; it only edits src/web/pages/migrate.ts, docs/ORIGINS.md and test/migrate.test.ts. I ran test/capacity.test.ts here and all 11 tests passed, with the default timeout and with --timeout 30000. My guess is a timing flake under load, since the 5-second default also tripped some setup steps here. I made no change for it, and only the new push will show whether the forge's check still fails.

What this adds

  • from selects the matching repository in the origin picker. The host is the origin's host as the picker shows it, port included.
  • crew selects that agent in the Agent dropdown. There is no separate "put a crew on it" checkbox; choosing an agent is what puts a crew on it.
  • A value that matches nothing selects nothing, and one escaped line names it, for example "No repository … in your origins." or "No agent … you can put on a crew."
  • Both values get a length cap and a character check, and from is also checked as a safe ref past the host.
  • Matching reads the origin lists the page already fetches, so there is no second fetch. POST is unchanged and keeps its same-origin check.
  • docs/ORIGINS.md (Migrate section) documents the link form.
  • test/migrate.test.ts covers four things: the prefill selects, a mismatch is ignored and named, hostile values are escaped, and the GETs create no repository.

This push: I split the link validation into linkRepo and linkAgent so each reads plainly. test/migrate.test.ts and test/capacity.test.ts pass together (20 tests, --timeout 30000). The type check still isn't run, because tsc can't find the bun types here.

Left out: an explicit source query param still overrides from, as before. The prefill doesn't set Autonomous.

To try it: connect an origin, then open /migrate?from=<origin host>/<owner>/<name>&crew=<agent>.

🤖 Generated with Claude Code

Closes #1006

commented

Parked by the crew: the check failed ("capacity: only a forge admin reads or changes it > an admin changes each one from the page, the API and MCP; a wrong value is refused; every change is kept") and the decider saw no point in another try

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs