Skip to content

Commit 6e17a80

Browse files
fix: address CI validation failures
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent f02ae8a commit 6e17a80

File tree

2 files changed

+4
-11
lines changed

2 files changed

+4
-11
lines changed

docs/features/custom-agents.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -840,7 +840,7 @@ session = await client.create_session(
840840
```go
841841
session, err := client.CreateSession(ctx, &copilot.SessionConfig{
842842
Tools: []copilot.Tool{heavyTool},
843-
defaultAgent: &copilot.DefaultAgentConfig{
843+
DefaultAgent: &copilot.DefaultAgentConfig{
844844
ExcludedTools: []string{"analyze-codebase"},
845845
},
846846
CustomAgents: []copilot.CustomAgentConfig{
@@ -863,7 +863,7 @@ session, err := client.CreateSession(ctx, &copilot.SessionConfig{
863863
var session = await client.CreateSessionAsync(new SessionConfig
864864
{
865865
Tools = [analyzeCodebaseTool],
866-
defaultAgent = new DefaultAgentConfig
866+
DefaultAgent = new DefaultAgentConfig
867867
{
868868
ExcludedTools = ["analyze-codebase"],
869869
},

nodejs/test/e2e/mcp_and_agents.test.ts

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,7 @@ import { dirname, resolve } from "path";
66
import { fileURLToPath } from "url";
77
import { describe, expect, it } from "vitest";
88
import { z } from "zod";
9-
import type {
10-
CustomAgentConfig,
11-
DefaultAgentConfig,
12-
MCPStdioServerConfig,
13-
MCPServerConfig,
14-
} from "../../src/index.js";
9+
import type { CustomAgentConfig, MCPStdioServerConfig, MCPServerConfig } from "../../src/index.js";
1510
import { approveAll, defineTool } from "../../src/index.js";
1611
import { createSdkTestContext } from "./harness/sdkTestContext.js";
1712

@@ -332,9 +327,7 @@ describe("MCP Servers and Custom Agents", async () => {
332327
// The real assertion: verify the runtime excluded the tool from the CAPI request
333328
const exchanges = await openAiEndpoint.getExchanges();
334329
const toolNames = exchanges.flatMap((e) =>
335-
(e.request.tools ?? []).map((t) =>
336-
"function" in t ? t.function.name : "",
337-
),
330+
(e.request.tools ?? []).map((t) => ("function" in t ? t.function.name : ""))
338331
);
339332
expect(toolNames).not.toContain("secret_tool");
340333

0 commit comments

Comments
 (0)