mirror of
https://github.com/stablyai/orca.git
synced 2026-10-04 00:02:21 +00:00
fix(native-chat): preserve rpc defaults across main merge
This commit is contained in:
@@ -317,13 +317,14 @@ describe('orchestration while Structured Chat owns an agent session', () => {
|
||||
it('settles worker_done while its pane remains in Structured Chat', async () => {
|
||||
const run = createRun()
|
||||
const task = db.createTask({ spec: 'Finish from Structured Chat', runId: run.id })
|
||||
const dispatch = db.createDispatchContext(
|
||||
task.id,
|
||||
WORKER.handle,
|
||||
paneKey(WORKER),
|
||||
undefined,
|
||||
runtime.getTerminalProcessIncarnation(WORKER.handle) ?? undefined
|
||||
)
|
||||
const dispatch = db.createDispatchContext({
|
||||
taskId: task.id,
|
||||
assigneeHandle: WORKER.handle,
|
||||
assigneePaneKey: paneKey(WORKER),
|
||||
processIncarnation: runtime.getTerminalProcessIncarnation(WORKER.handle) ?? undefined,
|
||||
creator: { kind: 'system' },
|
||||
maxDepth: Number.MAX_SAFE_INTEGER
|
||||
})
|
||||
const capability = db.mintDispatchCapability({
|
||||
dispatchId: dispatch.id,
|
||||
paneKey: paneKey(WORKER),
|
||||
|
||||
@@ -9,6 +9,7 @@ import {
|
||||
} from './core'
|
||||
|
||||
import { errorResponse, successResponse } from './errors'
|
||||
import { ALL_RPC_METHODS } from './methods'
|
||||
import { emulatorProbe, emulatorProbeError } from '../../emulator/emulator-probe'
|
||||
import type { OrcaRuntimeService } from '../orca-runtime'
|
||||
import {
|
||||
@@ -26,7 +27,7 @@ import { routeDispatcherClientHostedBrowserRpc } from './dispatcher-client-brows
|
||||
import { needsLocalCallerFingerprint } from './dispatcher-caller-fingerprint'
|
||||
import { createDispatcherStreamingFeatureEmitter } from './dispatcher-streaming-feature-emitter'
|
||||
|
||||
export type DispatcherOptions = { runtime: OrcaRuntimeService; methods: readonly RpcAnyMethod[] }
|
||||
export type DispatcherOptions = { runtime: OrcaRuntimeService; methods?: readonly RpcAnyMethod[] }
|
||||
|
||||
// oxfmt-ignore
|
||||
type DispatchCallOptions = Pick<RpcDispatchStreamingOptions, 'signal' | 'clientId' | 'clientKind' | 'clientCapabilities' | 'authenticatedCallerFingerprint'>
|
||||
@@ -37,7 +38,7 @@ export class RpcDispatcher {
|
||||
private readonly orchestrationMutations: OrchestrationMutationExecutor
|
||||
private readonly legacyOrchestration: OrchestrationLegacyCompatibility
|
||||
|
||||
constructor({ runtime, methods }: DispatcherOptions) {
|
||||
constructor({ runtime, methods = ALL_RPC_METHODS }: DispatcherOptions) {
|
||||
this.runtime = runtime
|
||||
this.registry = buildRegistry(methods)
|
||||
this.orchestrationMutations = getOrchestrationMutationExecutor(runtime)
|
||||
|
||||
Reference in New Issue
Block a user