fix(prompt-gate): harden sync and team prompt dispatch

This commit is contained in:
YeonGyu-Kim
2026-05-19 17:43:37 +09:00
parent 1492bffd20
commit bcea4a9d28
44 changed files with 688 additions and 140 deletions
+2 -2
View File
@@ -849,7 +849,7 @@ describe("ralph-loop", () => {
mockSessionMessages = [
{ info: { role: "user" }, parts: [{ type: "text", text: "Build something" }] },
{
info: { role: "assistant" },
info: { role: "assistant", finish: "end_turn" },
parts: [
{ type: "reasoning", text: "I am done now. <promise>REASONING_DONE</promise>" },
],
@@ -1398,7 +1398,7 @@ Original task: Build something`
mockSessionMessages = [
{
info: { role: "assistant" },
info: { role: "assistant", finish: "end_turn" },
parts: [{ type: "text", text: "All work is complete. <promise>DONE</promise>" }],
},
]
@@ -109,7 +109,7 @@ describe("ralph-loop user message race guard", () => {
})
messagesBySession["session-123"] = [
{ info: { role: "user", time: { created: Date.now() - 1_000 } } },
{ info: { role: "assistant", agent: "sisyphus", time: { created: Date.now() - 500 } } },
{ info: { role: "assistant", finish: "end_turn", agent: "sisyphus", time: { created: Date.now() - 500 } } },
]
try {