From c0242b0efe9cd7541cc9d03f751c8675c2bbb3f6 Mon Sep 17 00:00:00 2001 From: creatixchu Date: Wed, 18 Nov 2026 18:21:51 +0800 Subject: [PATCH] Restore SDK expectations and use the public inbox view in cleanup tests --- packages/experimental/cua/tests/run-code-composition.spec.ts | 2 +- .../snapshots/python-sdk-single-exe/advanced-ptc/result.json | 4 ++-- .../python-sdk-single-exe/advanced-ptc/session.v4.jsonl | 2 +- scripts/snapshots/python-sdk-single-exe/advanced/result.json | 4 ++-- .../snapshots/python-sdk-single-exe/advanced/session.v4.jsonl | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/experimental/cua/tests/run-code-composition.spec.ts b/packages/experimental/cua/tests/run-code-composition.spec.ts index 70b6edd9f1..d0fe9bfdda 100644 --- a/packages/experimental/cua/tests/run-code-composition.spec.ts +++ b/packages/experimental/cua/tests/run-code-composition.spec.ts @@ -604,7 +604,7 @@ it('does not resume retained inbox work when stopped during post-turn cleanup', await running expect(f.native.held).toEqual([]) expect(f.agent.session.snapshotEvents().filter(event => event.type === 'turn/start')).toHaveLength(1) - expect(f.agent.inbox.hasPending).toBe(true) + expect(f.agent.inbox.nextStep).toHaveLength(1) }) it('ignores an unattached Session ending while another task holds input', async () => { diff --git a/scripts/snapshots/python-sdk-single-exe/advanced-ptc/result.json b/scripts/snapshots/python-sdk-single-exe/advanced-ptc/result.json index 670bf27fe6..590a5001e8 100644 --- a/scripts/snapshots/python-sdk-single-exe/advanced-ptc/result.json +++ b/scripts/snapshots/python-sdk-single-exe/advanced-ptc/result.json @@ -984,7 +984,7 @@ "item": { "messageId": "{{message:1}}", "rating": "positive", - "note": "Turn resources released.", + "note": "The explanation is clear now.", "version": "{{feedback-version:2}}", "createdAt": 0, "updatedAt": 0 @@ -2258,7 +2258,7 @@ "item": { "messageId": "{{message:1}}", "rating": "positive", - "note": "Turn resources released.", + "note": "The explanation is clear now.", "version": "{{feedback-version:2}}", "createdAt": 0, "updatedAt": 0 diff --git a/scripts/snapshots/python-sdk-single-exe/advanced-ptc/session.v4.jsonl b/scripts/snapshots/python-sdk-single-exe/advanced-ptc/session.v4.jsonl index 1259ffbba5..799360745b 100644 --- a/scripts/snapshots/python-sdk-single-exe/advanced-ptc/session.v4.jsonl +++ b/scripts/snapshots/python-sdk-single-exe/advanced-ptc/session.v4.jsonl @@ -45,6 +45,6 @@ {"type":"command/done","data":{"commandId":"{{command:1}}","kind":"success","text":"Feedback recorded for session {{parent}}\nAnonymous user: {{anonymous-user}}."}} {"type":"feedback/record","data":{"category":"other"}} {"type":"feedback/message-put","data":{"sessionId":"{{parent}}","item":{"messageId":"{{message:1}}","rating":"negative","note":"Explain the result.","category":"task-result","version":"{{feedback-version:1}}","createdAt":0,"updatedAt":0}}} -{"type":"feedback/message-put","data":{"sessionId":"{{parent}}","item":{"messageId":"{{message:1}}","rating":"positive","note":"Turn resources released.","version":"{{feedback-version:2}}","createdAt":0,"updatedAt":0}}} +{"type":"feedback/message-put","data":{"sessionId":"{{parent}}","item":{"messageId":"{{message:1}}","rating":"positive","note":"The explanation is clear now.","version":"{{feedback-version:2}}","createdAt":0,"updatedAt":0}}} {"type":"feedback/message-delete","data":{"sessionId":"{{parent}}","messageId":"{{message:1}}"}} {"type":"turn/end","data":{"turn":1,"reason":{"kind":"completed"}}} diff --git a/scripts/snapshots/python-sdk-single-exe/advanced/result.json b/scripts/snapshots/python-sdk-single-exe/advanced/result.json index 3a704fd34e..78a94e27da 100644 --- a/scripts/snapshots/python-sdk-single-exe/advanced/result.json +++ b/scripts/snapshots/python-sdk-single-exe/advanced/result.json @@ -1460,7 +1460,7 @@ "item": { "messageId": "{{message:1}}", "rating": "positive", - "note": "Turn resources released.", + "note": "The explanation is clear now.", "version": "{{feedback-version:2}}", "createdAt": 0, "updatedAt": 0 @@ -4868,7 +4868,7 @@ "item": { "messageId": "{{message:1}}", "rating": "positive", - "note": "Turn resources released.", + "note": "The explanation is clear now.", "version": "{{feedback-version:2}}", "createdAt": 0, "updatedAt": 0 diff --git a/scripts/snapshots/python-sdk-single-exe/advanced/session.v4.jsonl b/scripts/snapshots/python-sdk-single-exe/advanced/session.v4.jsonl index 776cc9dcc1..6681e94bc0 100644 --- a/scripts/snapshots/python-sdk-single-exe/advanced/session.v4.jsonl +++ b/scripts/snapshots/python-sdk-single-exe/advanced/session.v4.jsonl @@ -62,6 +62,6 @@ {"type":"command/done","data":{"commandId":"{{command:1}}","kind":"success","text":"Feedback recorded for session {{parent}}\nAnonymous user: {{anonymous-user}}."}} {"type":"feedback/record","data":{"category":"other"}} {"type":"feedback/message-put","data":{"sessionId":"{{parent}}","item":{"messageId":"{{message:1}}","rating":"negative","note":"Explain the result.","category":"task-result","version":"{{feedback-version:1}}","createdAt":0,"updatedAt":0}}} -{"type":"feedback/message-put","data":{"sessionId":"{{parent}}","item":{"messageId":"{{message:1}}","rating":"positive","note":"Turn resources released.","version":"{{feedback-version:2}}","createdAt":0,"updatedAt":0}}} +{"type":"feedback/message-put","data":{"sessionId":"{{parent}}","item":{"messageId":"{{message:1}}","rating":"positive","note":"The explanation is clear now.","version":"{{feedback-version:2}}","createdAt":0,"updatedAt":0}}} {"type":"feedback/message-delete","data":{"sessionId":"{{parent}}","messageId":"{{message:1}}"}} {"type":"turn/end","data":{"turn":1,"reason":{"kind":"completed"}}}