Preserve history when deduplicating agent sessions (#471)

* fix(hub): merge histories for duplicate agent sessions

* fix(hub,web): refresh active duplicate history merges

* fix(hub): avoid active-active history merges

* fix(web): reset message window on history invalidation

---------

Co-authored-by: Liu-KM <Liu-KM@users.noreply.github.com>
This commit is contained in:
Qianli Liu
2026-04-21 13:56:50 +08:00
committed by GitHub
co-authored by Liu-KM
parent 1cb353b7b3
commit f097f10716
5 changed files with 217 additions and 59 deletions
+3
View File
@@ -214,6 +214,9 @@ export const SyncEventSchema = z.discriminatedUnion('type', [
type: z.literal('message-received'),
message: DecryptedMessageSchema
}),
SessionChangedSchema.extend({
type: z.literal('messages-invalidated')
}),
MachineChangedSchema.extend({
type: z.literal('machine-updated'),
data: z.unknown().optional()