feat: add task artifact validation for code runs
This commit is contained in:
@@ -24,6 +24,7 @@ import {
|
||||
syncUserMemory,
|
||||
updateProvider,
|
||||
} from '../api/client';
|
||||
import type { AgentRun } from '../api/client';
|
||||
import { appConfig } from '../config';
|
||||
import {
|
||||
clearStoredSessionId,
|
||||
@@ -74,8 +75,8 @@ const FINISH_SYNC_RETRY_DELAYS_MS = [500, 1500, 3000];
|
||||
const ACTIVE_REQUEST_MISSING_GRACE_MS = 2500;
|
||||
export { INSUFFICIENT_BALANCE_NOTICE };
|
||||
|
||||
async function waitForAgentRun(runId: string) {
|
||||
return await new Promise((resolve, reject) => {
|
||||
async function waitForAgentRun(runId: string): Promise<AgentRun> {
|
||||
return await new Promise<AgentRun>((resolve, reject) => {
|
||||
const unsubscribe = subscribeAgentRunEvents(
|
||||
runId,
|
||||
(run) => {
|
||||
@@ -1177,6 +1178,7 @@ export function useTKMindChat(
|
||||
taskType: 'h5_chat_code_task',
|
||||
userId: userRef.current?.id ?? null,
|
||||
requestId,
|
||||
mindspaceContext: options?.mindspaceContext ?? null,
|
||||
}),
|
||||
);
|
||||
const finishedRun =
|
||||
|
||||
Reference in New Issue
Block a user