mirror of
https://github.com/stablyai/orca.git
synced 2026-11-13 09:27:29 +00:00
Align restart warnings and satisfy changed-file lint rules
This commit is contained in:
@@ -13,6 +13,7 @@ it.each([10, 100])('drains %i live roots without rescanning retained outcomes',
|
||||
const child = Object.assign(new EventEmitter(), { pid: 42, kill: vi.fn(() => true) })
|
||||
children.push(child)
|
||||
queueMicrotask(() => child.emit('spawn'))
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: This held-child fixture supplies the PID, events and kill method used by the provider registry.
|
||||
return child as never
|
||||
})
|
||||
const owner = new Socket()
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import type { DaemonClientConnections } from './daemon-client-connections'
|
||||
import type { DaemonClientConnections, ConnectedDaemonClient } from './daemon-client-connections'
|
||||
import type { DaemonTerminalAdmission } from './daemon-terminal-admission'
|
||||
import type { TerminalHost } from '../terminal-host/terminal-host'
|
||||
import type { DaemonRequest } from '../protocol/daemon-rpc-contract'
|
||||
import type { ConnectedDaemonClient } from './daemon-client-connections'
|
||||
import type { DaemonProviderProcesses } from './daemon-provider-processes'
|
||||
import type { DaemonServerLifecycle } from './daemon-server-lifecycle'
|
||||
|
||||
|
||||
@@ -141,6 +141,7 @@ function parseDaemonEndpointIdentity(value: unknown): DaemonEndpointIdentity | n
|
||||
if (!value || typeof value !== 'object') {
|
||||
return null
|
||||
}
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: Only optional unknown fields are projected after the object check; values are validated below.
|
||||
const identity = value as {
|
||||
pid?: unknown
|
||||
startedAtMs?: unknown
|
||||
|
||||
@@ -25,6 +25,7 @@ export function attachControlResponseReader(
|
||||
const parser = createNdjsonParser(
|
||||
(msg) => {
|
||||
if (msg && typeof msg === 'object' && 'type' in msg && msg.type === 'providerExit') {
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: The authenticated daemon emits this tagged record through its typed provider outcome encoder.
|
||||
onProviderEvent?.(msg as HostedProviderExitEvent)
|
||||
} else {
|
||||
onResponse(msg as RpcResponse)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PiRpcConnection } from './rpc-session'
|
||||
import type { PiRpcConnection, PiRpcSession } from './rpc-session'
|
||||
import { waitForPromiseWithSignal } from '../../../shared/abort-signal-reason'
|
||||
import type {
|
||||
StructuredAgentSessionAcquireInput,
|
||||
@@ -8,7 +8,6 @@ import type { AgentSessionStartEndings } from '../../native-chat/agent-session-w
|
||||
import type { StructuredAgentSessionProviderOpenInput } from '../../native-chat/agent-session-wire/startup/structured-agent-session-provider-open-contract'
|
||||
import { JsonlRpcAgentExitError } from '../../jsonl-rpc/agent-connection'
|
||||
import { withProviderSpawnAbsence } from '../../provider-process/provider-executable-missing'
|
||||
import type { PiRpcSession } from './rpc-session'
|
||||
import { piStartFailure } from './rpc-startup-outcome'
|
||||
|
||||
/** Takes this child's own exit when first seen, so a start settling meanwhile cannot miss it; the
|
||||
|
||||
@@ -80,6 +80,7 @@ function pendingChild() {
|
||||
}
|
||||
const child = new HostedProviderChild(
|
||||
spec,
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: The fixture implements the daemon methods exercised by the hosted child without opening real daemon sockets.
|
||||
async () => client as never,
|
||||
() => {
|
||||
throw new Error('Duplicate spawn')
|
||||
@@ -204,6 +205,7 @@ it('keeps a bounded startup longer than one second hosted instead of spawning tw
|
||||
handle.exit()
|
||||
await vi.advanceTimersByTimeAsync(1_001)
|
||||
const startup = Promise.withResolvers<typeof handle.client>()
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: Startup resolves to the same daemon-method fixture exercised by the hosted child.
|
||||
installProviderProcessHost(async () => startup.promise as never)
|
||||
const direct = vi.fn(() => {
|
||||
throw new Error('Unexpected fallback')
|
||||
@@ -243,6 +245,7 @@ it('keeps direct-fallback tree cleanup when its first stop signal fails', async
|
||||
async () => null,
|
||||
() => {
|
||||
queueMicrotask(() => direct.emit('spawn'))
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: The fixture supplies the streams, PID, events and kill result consumed by direct-child adoption and teardown.
|
||||
return direct as never
|
||||
}
|
||||
)
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import { installProviderProcessHost } from '../../provider-process/provider-process-spawn'
|
||||
import { getProviderProcessHostClient } from '../../daemon/providers/lifecycle/daemon-provider-state'
|
||||
import { app } from 'electron'
|
||||
import { parseWorkspaceKey } from '../../../shared/workspace-scope'
|
||||
import { isLocalExecutionHost } from '../../../shared/execution-host'
|
||||
@@ -8,6 +7,7 @@ import { track } from '../../telemetry/client'
|
||||
import { getPtyIdForPaneKey } from '../../ipc/pty/pane/key-state'
|
||||
import {
|
||||
getDaemonProvider,
|
||||
getProviderProcessHostClient,
|
||||
listLiveDaemonPtyIds
|
||||
} from '../../daemon/providers/lifecycle/daemon-provider-state'
|
||||
import { initDaemonPtyProvider } from '../../daemon/providers/lifecycle/daemon-provider-init'
|
||||
|
||||
@@ -116,7 +116,7 @@ function FixSteps({
|
||||
? undefined
|
||||
: t(
|
||||
'auto.components.shared.MacFolderAccessFixDialog.restartConsequence',
|
||||
'Terminals and agents using this service will close.'
|
||||
'Open terminals restart; running agents stop.'
|
||||
)
|
||||
}
|
||||
/>
|
||||
|
||||
@@ -238,7 +238,7 @@ function getCopy(kind: DaemonActionKind, t: Translate = translate): DaemonAction
|
||||
<>
|
||||
{t(
|
||||
'auto.components.shared.useDaemonActions.01d6b7c64e',
|
||||
'Terminals and agents using this service will close. Remote hosts are not affected.'
|
||||
'Open terminals restart; running agents stop. Remote hosts are not affected.'
|
||||
)}
|
||||
</>
|
||||
),
|
||||
|
||||
@@ -6747,7 +6747,7 @@
|
||||
"d9657ac204": "ターミナルセッションのシャットダウンリクエストが送信されました。",
|
||||
"e8f25bd903": "ターミナルクリーンアップを完了できませんでした。",
|
||||
"a702d4196e": "これにより、すべてのワークスペースのターミナルタブが閉じられ、現在のターミナルセッションのシャットダウンがリクエストされます。保存されていないターミナル作業は失われます。デーモン自体は実行を続け、新規ターミナルはすぐに開けます。この操作は取り消せません。",
|
||||
"01d6b7c64e": "開いているターミナルは再起動し、実行中のエージェントは停止します。リモートホストには影響しません。",
|
||||
"01d6b7c64e": "開いているターミナルは再起動し、実行中の Agent は停止します。リモートホストには影響しません。",
|
||||
"922548bc66": "ターミナルサービスを再起動しますか?",
|
||||
"confirmRestart": "再起動",
|
||||
"busyRestarting": "再起動中…",
|
||||
@@ -6758,7 +6758,7 @@
|
||||
"stepAllow": "ファイルとフォルダーで Orca を許可する",
|
||||
"openSystemSettings": "システム設定を開く",
|
||||
"stepRestart": "Orca のターミナルサービスを再起動",
|
||||
"restartConsequence": "開いているターミナルは再起動し、実行中のエージェントは停止します。",
|
||||
"restartConsequence": "開いているターミナルは再起動し、実行中の Agent は停止します。",
|
||||
"restarting": "再起動中…",
|
||||
"restart": "再起動",
|
||||
"restartFailed": "再起動に失敗しました。 「設定」→「ターミナル」→「セッションの管理」から再試行してください。",
|
||||
|
||||
Reference in New Issue
Block a user