Skip to content

refactor(cli/github+run): Stage 4 — drop AppRuntime.runPromise bridges#25539

Merged
kitlangton merged 1 commit intodevfrom
kit/cli-flatten-run-github
May 3, 2026
Merged

refactor(cli/github+run): Stage 4 — drop AppRuntime.runPromise bridges#25539
kitlangton merged 1 commit intodevfrom
kit/cli-flatten-run-github

Conversation

@kitlangton
Copy link
Copy Markdown
Contributor

Summary

Continues the Stage 4 cleanup arc — drops the remaining inline AppRuntime.runPromise(Service.use(...)) bridges in cli/cmd/github.ts and cli/cmd/run.ts.

  • github.ts: yield Git / Session / SessionShare / SessionPrompt / ModelsDev once at the top of each handler; replace the 8 inline AppRuntime.runPromise(...) sites with Effect.runPromise(svc.method(...)) on the in-scope service.
  • run.ts: same pattern for the single Agent.Service.get site.
  • Removes the now-unused AppRuntime imports from both files.

Pure refactor — services already had typed R = Service requirements, just lifted them up one level so the runtime resolves them once instead of per-call. No behavior change.

Test plan

  • bun run typecheck clean
  • bun run test test/cli/github-action.test.ts test/cli/github-remote.test.ts — 31 pass

github.ts: yield Git/Session/SessionShare/SessionPrompt/ModelsDev once at
the top of each handler; replace inline AppRuntime.runPromise(Service.use(...))
calls with Effect.runPromise on the in-scope service.

run.ts: same pattern for the single Agent.Service.get site.

Drop the now-unused AppRuntime imports.
@kitlangton kitlangton force-pushed the kit/cli-flatten-run-github branch from 86c4438 to e64d3ac Compare May 3, 2026 15:34
@kitlangton kitlangton merged commit df7dd06 into dev May 3, 2026
10 checks passed
@kitlangton kitlangton deleted the kit/cli-flatten-run-github branch May 3, 2026 15:42
oleksii-honchar pushed a commit to oleksii-honchar/better-opencode that referenced this pull request May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant