@codeany/open-agent-sdk 0.2.0 → 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/engine.ts +3 -0
package/package.json CHANGED
@@ -12,7 +12,7 @@
12
12
  "bugs": {
13
13
  "url": "https://github.com/codeany-ai/open-agent-sdk-typescript/issues"
14
14
  },
15
- "version": "0.2.0",
15
+ "version": "0.2.2",
16
16
  "description": "Open-source Agent SDK. Runs the full agent loop in-process — no local CLI required. Deploy anywhere: cloud, serverless, Docker, CI/CD.",
17
17
  "type": "module",
18
18
  "main": "./dist/index.js",
package/src/engine.ts CHANGED
@@ -315,12 +315,15 @@ export class QueryEngine {
315
315
  }
316
316
  }
317
317
 
318
+ const message = err?.message ? String(err.message) : String(err)
319
+
318
320
  yield {
319
321
  type: 'result',
320
322
  subtype: 'error',
321
323
  usage: this.totalUsage,
322
324
  num_turns: this.turnCount,
323
325
  cost: this.totalCost,
326
+ errors: [message],
324
327
  }
325
328
  return
326
329
  }