fix: surface AgentRun resource failures in human output
This commit is contained in:
@@ -81,9 +81,7 @@ assertCondition(
|
||||
agentRunSource.includes('type AgentRunBridgeCaptureBackend = "local-backend-core-broker" | "remote-frontend-websocket"')
|
||||
&& agentRunSource.includes('reason: "runner-environment"')
|
||||
&& agentRunSource.includes('degradedReason: "capture-backend-unavailable"')
|
||||
&& agentRunSource.includes('"agentrun-cli-returned-failure"')
|
||||
&& agentRunSource.includes('failureKind: "bridge-execution-environment"')
|
||||
&& agentRunSource.includes('key === "nextActions"'),
|
||||
&& agentRunSource.includes('failureKind: "bridge-execution-environment"'),
|
||||
"AgentRun CLI bridge must use the remote frontend backend in runner/no-Docker environments and classify bridge failures separately",
|
||||
);
|
||||
|
||||
@@ -100,13 +98,23 @@ assertCondition(
|
||||
);
|
||||
|
||||
assertCondition(
|
||||
agentRunSource.includes('if (verb === "dispatch") return await resourceDispatch(config, command, action, actionArgs, options);')
|
||||
&& agentRunSource.includes('runOfficialAgentRunCli(config, "queue", ["dispatch", ref.name')
|
||||
&& agentRunSource.includes('"list", "--state", taskListState(options)')
|
||||
agentRunSource.includes('if (verb === "dispatch") return await resourceDispatch')
|
||||
&& agentRunSource.includes('bridgeActionArgs, options')
|
||||
&& agentRunSource.includes('runAgentRunRestCommand(config, "queue", ["dispatch"')
|
||||
&& agentRunSource.includes('taskListState(options)')
|
||||
&& agentRunSource.includes('["commander", "--reader-id", options.readerId'),
|
||||
"AgentRun resources must wrap task dispatch and keep default get tasks on active list visibility",
|
||||
);
|
||||
|
||||
assertCondition(
|
||||
agentRunSource.includes("function renderFailureLines(value: Record<string, unknown>): string[]")
|
||||
&& agentRunSource.includes('lines.push(`Failure: ${failureKind}`)')
|
||||
&& agentRunSource.includes('lines.push(`Message: ${failureMessage}`)')
|
||||
&& agentRunSource.includes("const failure = renderFailureLines(data);")
|
||||
&& agentRunSource.includes("const failure = renderFailureLines(value);"),
|
||||
"AgentRun resource human output must expose failure kind and message without requiring JSON output",
|
||||
);
|
||||
|
||||
assertCondition(
|
||||
agentRunSource.includes("const effectiveLimit = options.tail ?? options.limit;")
|
||||
&& agentRunSource.includes("return renderEventLike(command, result, { ...options, limit: effectiveLimit }, \"Log\""),
|
||||
@@ -134,6 +142,7 @@ console.log(JSON.stringify({
|
||||
"AgentRun CLI bridge keeps AgentRun failures distinct from bridge failures",
|
||||
"AgentRun resource parser supports apply -f -",
|
||||
"AgentRun resource task dispatch and active task list visibility",
|
||||
"AgentRun resource failure output is visible in human mode",
|
||||
"AgentRun logs tail controls page limit",
|
||||
"AgentRun dry-run mutations keep resource-command follow-up",
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user