mirror of
https://github.com/wu736139669/hapi.git
synced 2026-11-26 05:27:06 +00:00
fix(codex): fork archived sessions without reopening the source (#2231)
* fix(codex): fork archived sessions without reopening the source * fix(codex): reconcile interrupted archived fork recovery * fix(codex): release rejected forks and serialize source startup * fix(codex): fence unconfirmed resume startup across retries * test(codex): validate durable resume recovery and serialize archive * fix(codex): block local resume of pending archived fork sources * fix(hub): coalesce concurrent resume requests to preserve idempotent startup * fix(hub): bypass startup coalescing for PTY sessions
This commit is contained in:
@@ -656,6 +656,17 @@ export type ForkConversationRpcResponse = ForkConversationRpcResult | {
|
||||
error: string
|
||||
}
|
||||
|
||||
/** Machine-scoped native history operation; never sends a source prompt. */
|
||||
export const ForkArchivedCodexRequestSchema = z.object({
|
||||
operationId: z.string().uuid(),
|
||||
sourceSessionId: z.string().uuid(),
|
||||
sourceThreadId: z.string().min(1),
|
||||
directory: z.string().min(1),
|
||||
boundary: z.object({ localId: z.string().min(1), turnId: z.string().min(1) }).optional()
|
||||
})
|
||||
export type ForkArchivedCodexRequest = z.infer<typeof ForkArchivedCodexRequestSchema>
|
||||
export type ForkArchivedCodexResponse = { nativeSessionId: string } | { error: string; rollbackSafe: boolean }
|
||||
|
||||
export type RewindConversationErrorCode =
|
||||
| 'ambiguous_native_boundary'
|
||||
| 'ambiguous_native_boundary_fork_safe'
|
||||
|
||||
Reference in New Issue
Block a user