feat(image): complete reviewed generation delivery
Memind CI / Test, build, and release guards (pull_request) Successful in 2m47s

This commit is contained in:
john
2026-07-20 20:04:44 +08:00
parent fc3d27aae0
commit 4b15610aa8
42 changed files with 1764 additions and 97 deletions
+23 -3
View File
@@ -286,6 +286,17 @@ function createFakePool({ sessionDeliverables = {}, workspaceDeliverables = {} }
const id = params.at(-1);
const row = runs.get(id);
if (!row) return [{ affectedRows: 0 }];
if (sql.includes("status = 'running'") && sql.includes('started_at = COALESCE(started_at, ?)')) {
const [attempts, startedAt, updatedAt] = params;
Object.assign(row, {
status: 'running',
attempts,
started_at: row.started_at ?? startedAt,
updated_at: updatedAt,
error_message: null,
});
return [{ affectedRows: 1 }];
}
const columns = [...sql.matchAll(/([a-z_]+) = \?/g)].map((match) => match[1]);
for (let i = 0; i < columns.length; i += 1) {
row[columns[i]] = params[i];
@@ -645,7 +656,8 @@ test('agent run succeeds when Finish is missing but session pages were already c
);
});
test('static page run succeeds when no Page Data artifact path is recorded', async () => {
test('static page run succeeds when workspace fallback reports the current HTML path', async () => {
let observedRunStartedAtMs = null;
const pool = createFakePool({
workspaceDeliverables: {
'user-1': [{
@@ -670,8 +682,15 @@ test('static page run succeeds when no Page Data artifact path is recorded', asy
return { ok: true, finishEvent: { type: 'Finish' } };
},
},
// This mirrors a static-page-publish run: no Page Data artifact list.
syncUserPagesOnSuccess: async () => ({ pageDataBind: { errors: [] }, pageDataRelativePaths: [] }),
// Static-page-publish may have no conversation artifact, but the server
// reports the current run's recently modified workspace HTML explicitly.
syncUserPagesOnSuccess: async ({ runStartedAtMs }) => {
observedRunStartedAtMs = runStartedAtMs;
return {
pageDataBind: { errors: [] },
pageDataRelativePaths: ['public/urban-fashion.html'],
};
},
retryDelaysMs: [],
});
@@ -684,6 +703,7 @@ test('static page run succeeds when no Page Data artifact path is recorded', asy
});
await waitFor(() => pool.runs.get(run.id)?.status === 'succeeded');
assert.ok(Number(observedRunStartedAtMs) > 0);
});
test('agent run uses direct chat service for eligible chat messages', async () => {