mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-09 07:33:57 +00:00
fix(agents): avoid repeated item progress snapshots (#101042)
* fix(agents): avoid repeated item progress snapshots * chore: align ACP branch with current main * fix(agents): deduplicate ACP parent progress * chore: keep release notes in PR context --------- Co-authored-by: Peter Steinberger <steipete@gmail.com> Co-authored-by: Peter Steinberger <peter@steipete.me>
This commit is contained in:
@@ -756,7 +756,7 @@ describe("startAcpSpawnParentStreamRelay", () => {
|
||||
relay.dispose();
|
||||
});
|
||||
|
||||
it("emits full preamble item progress after the previous snapshot flushed", () => {
|
||||
it("omits already flushed preamble item progress from later prefix snapshots", () => {
|
||||
const relay = startAcpSpawnParentStreamRelay({
|
||||
runId: "run-preamble-item-after-flush",
|
||||
parentSessionKey: "agent:main:main",
|
||||
@@ -790,7 +790,7 @@ describe("startAcpSpawnParentStreamRelay", () => {
|
||||
});
|
||||
vi.advanceTimersByTime(15);
|
||||
|
||||
expect(collectedTexts()).toEqual(["codex: Checking", "codex: Checking the app-server stream"]);
|
||||
expect(collectedTexts()).toEqual(["codex: Checking", "codex: the app-server stream"]);
|
||||
relay.dispose();
|
||||
});
|
||||
|
||||
|
||||
@@ -534,8 +534,7 @@ export function startAcpSpawnParentStreamRelay(params: {
|
||||
pendingText = "";
|
||||
}
|
||||
itemProgressTextById.set(snapshot.itemId, snapshot.text);
|
||||
const delta =
|
||||
isPrefixUpdate && hasPendingSnapshot ? snapshot.text.slice(previous.length) : snapshot.text;
|
||||
const delta = isPrefixUpdate ? snapshot.text.slice(previous.length) : snapshot.text;
|
||||
appendVisibleProgress(delta, kind);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user