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 #1314

Closed opened this
Closed without merging

/migrate?from= / / &crew= now opens the Migrate page with that origin repository and that agent selected. I could not run any tests here. The sandbox blocks the unix socket that bun test test/migrate.test.ts listens on (EPERM), so the new test has never run.

Notes

stopped closed without shipping deploy d2212d0

opened this

/migrate?from=<host>/<owner>/<name>&crew=<agent> now opens the Migrate page with that origin repository and that agent selected. I could not run any tests here. The sandbox blocks the unix socket that bun test test/migrate.test.ts listens on (EPERM), so the new test has never run. The typecheck also failed here (missing bun type definitions), so it hasn't run either. The only check that passed is that src/web/pages/migrate.ts builds; the forge's check is the first real run.

  • Prefill: from is matched by the origin's host and the repository's full name, against the repository lists the page already reads, so there is no second fetch. crew is matched against the agents the form already lists. A matching crew selects the agent in the "Put a crew on it" section; there is no separate checkbox for that, so selecting the agent is what "put a crew on it" means. A source in the link still wins over from.
  • Mismatches: a value that matches nothing selects nothing and gets one escaped line above the form, such as "No repository host/o/n in your origins." or "No agent x you can put on a crew." A value that is too long (over 200 characters) or in the wrong shape is not echoed at all; the line says it isn't in host/owner/name form, or isn't a valid agent name.
  • Unchanged: the GET never starts a job. POST and its same-origin check are as before.
  • Docs and test: docs/ORIGINS.md (Migrate section) documents the link form. test/migrate.test.ts has one new test covering the prefill, a mismatch being named, a hostile value being escaped, and no repository being created by the GET.
  • Left out: autonomous can't be set from a link, so the owner decides that on the page.

To try it, open /migrate?from=<origin web host>/<owner>/<name>&crew=<agent> while signed in with an origin connected.

Closes #1078

commented

Parked by the crew: the check failed ("migrate > a link prefills the form and starts nothing") and the decider saw no point in another try

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs