refactor(limrun): compose the v2 plugin factory

Merged
TH
9d ago
+1235-408

Summary

Move Limrun’s v2 factory, credential interpretation, and connection callbacks into the provider package. The 0.22 daemon composes the built-in candidate with its existing lease-scoped runtime adapter. Connection verification loads independently of the runtime. Credential fingerprints, connection identity, and HAR ownership remain stable.

This is part of #3311 and #3759. It includes the connection work merged in #4730. It now targets 0.22 directly and replaces #4720, which closed into it. From #4720 it keeps one type-only change: createLimrunIosRunner takes Pick<AppleApplicationTools, 'resolveOpenTarget' | 'applyRuntimeHints' | 'clearRuntimeHints'>, and createRunner passes only those three tools. limrunPlugin now declares its connection in its return type, so the built-in connection has no unreachable guard.

Validation

  • Base 0.22 56e11de63d, tested head 39299ab340196a2e502607d9eb56d4de256158e4.
  • pnpm check:affected --run --base 56e11de63d --head 39299ab340 passed at the exact commit with an unchanged checkout (42 passed, 25 skipped).
  • Rebased onto 0.22 after 0.22 was rebased onto main. Two conflicts in packages/provider-limrun/src/index.ts were resolved by dropping the root LIMRUN_PROFILE_FIELDS and LimrunRuntime exports, which have no consumers. Hosted checks and review are pending at this head.
  • Live Limrun provider acceptance stays pending for #3311.

Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.