@tea-agent/loop-agent 0.44.0-next.14 → 0.44.0-next.15
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.
- package/CHANGELOG.md +1 -0
- package/dist/build-stamp.json +3 -3
- package/dist/worker/console/chat/db-connections.js +1 -1
- package/dist/worker/console/chat/pi-runtime/custom-tools/sql-tools.js +18 -3
- package/dist/worker/console/static/pets/ember/pet.json +1 -1
- package/dist/worker/console/static/pets/ember/spritesheet.png +0 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# 更新日志
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
|
+
- GitHub CI 与 npm next 预发布只跑纯逻辑 fast 测试:不再安装 Chromium,也不跑真开浏览器或起 HTTP 服务的用例。这些用例仍由本地推送前检查、完整验证脚本和正式发布线覆盖。
|
|
4
5
|
- 修复 GitHub Actions Linux 上工作台浏览器起不来的问题:CI 没有可用 Chromium sandbox 时不再强制沙箱,桌面端仍保持沙箱以免出现 "unsupported command-line flag" 提示条。
|
|
5
6
|
- 对话预约漏填预算时,默认最多 5 次目标尝试、5 次任务执行和 4 次监督,执行窗口 240 分钟;确认卡会展示这些上限,第一次没通过还可以在预算内继续修。显式指定更小预算或更短窗口不会被抬高;写保护、无进展或监督决定停止时仍会停。已确认的旧预约不受影响。
|
|
6
7
|
- Operator Console 新增桌面宠物:移植 dsh-pet 的状态机、好感度、互动冷却、任务奖励与零食结算,宠物会跟随 Chat 的思考、工具调用、回复、完成和失败状态切换动画;支持拖动、摸摸、喂食及持久化;默认关闭,可在对话设置的「宠物」页开启。首个素材不复用 dsh 图片,改为仓库内脚本确定性生成的原创矢量橙色小精灵「小橘灵」:圆滚滚身体、小短手小短腿、叶子呆毛和火焰尾巴,嘴、手、尾巴、头部按对话状态做关节动画。
|
package/dist/build-stamp.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"version": "0.44.0-next.
|
|
4
|
-
"gitSha": "
|
|
5
|
-
"builtAt": "2026-09-
|
|
3
|
+
"version": "0.44.0-next.15",
|
|
4
|
+
"gitSha": "91e4ddc36f05be3f8f8a681826bc8d51d0f15c65",
|
|
5
|
+
"builtAt": "2026-09-19T12:41:22.445Z"
|
|
6
6
|
}
|
|
@@ -646,7 +646,7 @@ export class DbConnectionRegistry {
|
|
|
646
646
|
if (!existsSync(config.path)) {
|
|
647
647
|
throw new DbConnectionError("DB_ENGINE_ERROR", `sqlite database file does not exist: ${config.path}`);
|
|
648
648
|
}
|
|
649
|
-
const db = new DatabaseSync(config.path, { timeout: 5_000 });
|
|
649
|
+
const db = new DatabaseSync(config.path, { timeout: 5_000, readOnly: true });
|
|
650
650
|
return wrapSqlite(db);
|
|
651
651
|
}
|
|
652
652
|
catch (error) {
|
|
@@ -331,12 +331,14 @@ export async function buildSqlTools(options) {
|
|
|
331
331
|
return true;
|
|
332
332
|
return /connection lost|connection closed|connection ended|connection terminated|server closed the connection unexpectedly/i.test(message);
|
|
333
333
|
}
|
|
334
|
-
async function envelope(operation, timeoutMs) {
|
|
334
|
+
async function envelope(operation, timeoutMs, onTimeout) {
|
|
335
335
|
let result;
|
|
336
336
|
try {
|
|
337
337
|
result = await withTimeout(operation(), timeoutMs);
|
|
338
338
|
}
|
|
339
339
|
catch (error) {
|
|
340
|
+
if (error instanceof SqlToolError && error.code === "DB_TIMEOUT")
|
|
341
|
+
onTimeout?.();
|
|
340
342
|
const code = error instanceof SqlToolError
|
|
341
343
|
? error.code
|
|
342
344
|
: error instanceof Error && "code" in error
|
|
@@ -362,6 +364,19 @@ export async function buildSqlTools(options) {
|
|
|
362
364
|
return "DB_ENGINE_ERROR";
|
|
363
365
|
}
|
|
364
366
|
}
|
|
367
|
+
/** JSON-safe cell value: bigint -> decimal string, binary -> size placeholder. */
|
|
368
|
+
function jsonSafeValue(value) {
|
|
369
|
+
if (typeof value === "bigint")
|
|
370
|
+
return value.toString();
|
|
371
|
+
if (value instanceof Uint8Array)
|
|
372
|
+
return "<BLOB " + value.byteLength + "B>";
|
|
373
|
+
if (value instanceof Date)
|
|
374
|
+
return value.toISOString();
|
|
375
|
+
return value;
|
|
376
|
+
}
|
|
377
|
+
function jsonSafeRows(rows) {
|
|
378
|
+
return rows.map((row) => Object.fromEntries(Object.entries(row).map(([key, value]) => [key, jsonSafeValue(value)])));
|
|
379
|
+
}
|
|
365
380
|
async function withTimeout(promise, timeoutMs) {
|
|
366
381
|
let timer;
|
|
367
382
|
try {
|
|
@@ -420,7 +435,7 @@ export async function buildSqlTools(options) {
|
|
|
420
435
|
};
|
|
421
436
|
});
|
|
422
437
|
const truncated = all.length > limit;
|
|
423
|
-
const rows = truncated ? all.slice(0, limit) : all;
|
|
438
|
+
const rows = jsonSafeRows(truncated ? all.slice(0, limit) : all);
|
|
424
439
|
const format = params.format ?? "json";
|
|
425
440
|
let text;
|
|
426
441
|
if (format === "table")
|
|
@@ -438,7 +453,7 @@ export async function buildSqlTools(options) {
|
|
|
438
453
|
truncated,
|
|
439
454
|
...(text !== undefined ? { text } : {}),
|
|
440
455
|
};
|
|
441
|
-
}, SQL_QUERY_TIMEOUT_MS);
|
|
456
|
+
}, SQL_QUERY_TIMEOUT_MS, () => registry.evict(params.connection));
|
|
442
457
|
},
|
|
443
458
|
}),
|
|
444
459
|
defineTool({
|
|
@@ -162,6 +162,6 @@
|
|
|
162
162
|
"waiting"
|
|
163
163
|
]
|
|
164
164
|
},
|
|
165
|
-
"description": "
|
|
165
|
+
"description": "原创矢量橙色小精灵(精细版 v2:分层着色、描边、脚随身体、跳跃挤压拉伸),预渲染为 dsh 风格逐帧雪碧图,由 requestAnimationFrame 驱动。",
|
|
166
166
|
"license": "Original in-repo vector character rendered to a spritesheet."
|
|
167
167
|
}
|
|
Binary file
|