Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion packages/opencode/src/kilo-sessions/kilo-sessions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -634,7 +634,10 @@ export namespace KiloSessions {
log.info("full sync", { sessionId })

const session = await Session.get(SessionID.make(sessionId))
const diffs = await SessionSummary.diff({ sessionID: SessionID.make(sessionId) })
const { AppRuntime } = await import("@/effect/app-runtime")
const diffs = await AppRuntime.runPromise(
SessionSummary.Service.use((svc) => svc.diff({ sessionID: SessionID.make(sessionId) })),
)
const messages = await Array.fromAsync(MessageV2.stream(SessionID.make(sessionId)))
messages.reverse()
const models = await Promise.all(
Expand Down
6 changes: 0 additions & 6 deletions packages/opencode/src/session/summary.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import { withStatics } from "@/util/schema"
import * as Session from "./session"
import { MessageV2 } from "./message-v2"
import { SessionID, MessageID } from "./schema"
import { makeRuntime } from "@/effect/run-service" // kilocode_change

function unquoteGitPath(input: string) {
if (!input.startsWith('"')) return input
Expand Down Expand Up @@ -171,9 +170,4 @@ export const DiffInput = Schema.Struct({
}).pipe(withStatics((s) => ({ zod: zod(s) })))
export type DiffInput = Schema.Schema.Type<typeof DiffInput>

// kilocode_change start - legacy promise helpers for Kilo callsites
const { runPromise } = makeRuntime(Service, defaultLayer)
export const diff = (input: { sessionID: SessionID; messageID?: MessageID }) => runPromise((svc) => svc.diff(input))
// kilocode_change end

export * as SessionSummary from "./summary"
1 change: 0 additions & 1 deletion script/check-opencode-promise-facades.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ const allow: Record<string, string> = {
"session/compaction.ts": "existing compaction facade outside #10655",
"session/prompt.ts": "transitional facade tracked by #10655",
"session/session.ts": "transitional facade tracked by #10655",
"session/summary.ts": "transitional facade removed by #10620",
"sync/index.ts": "sync event runtime boundary",
"tool/registry.ts": "transitional facade removed by #10620",
}
Expand Down
Loading