Skip to content

Commit a22c886

Browse files
authored
Update @github/copilot to 0.0.387 (github#54)
* Update @github/copilot to 0.0.387 * Regenerate session types * Restore custom python session types
1 parent af66bfd commit a22c886

File tree

6 files changed

+194
-49
lines changed

6 files changed

+194
-49
lines changed

dotnet/src/Generated/SessionEvents.cs

Lines changed: 56 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
//
77
// Generated from: @github/copilot/session-events.schema.json
88
// Generated by: scripts/generate-session-types.ts
9-
// Generated at: 2026-01-16T00:52:52.781Z
9+
// Generated at: 2026-01-20T04:18:06.775Z
1010
//
1111
// To update these types:
1212
// 1. Update the schema in copilot-agent-runtime
@@ -78,7 +78,7 @@ internal class SessionEventConverter : JsonConverter<SessionEvent>
7878
throw new JsonException("Missing 'type' discriminator property");
7979

8080
if (!TypeMap.TryGetValue(typeProp, out var targetType))
81-
return null; // Ignore unknown event types for forward compatibility
81+
throw new JsonException($"Unknown event type: {typeProp}");
8282

8383
// Deserialize to the concrete type without using this converter (to avoid recursion)
8484
return (SessionEvent?)obj.Deserialize(targetType, SerializerOptions.WithoutConverter);
@@ -505,6 +505,10 @@ public partial class SessionStartData
505505
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
506506
[JsonPropertyName("selectedModel")]
507507
public string SelectedModel { get; set; }
508+
509+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
510+
[JsonPropertyName("context")]
511+
public SessionStartDataContext? Context { get; set; }
508512
}
509513

510514
public partial class SessionResumeData
@@ -514,6 +518,10 @@ public partial class SessionResumeData
514518

515519
[JsonPropertyName("eventCount")]
516520
public double EventCount { get; set; }
521+
522+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
523+
[JsonPropertyName("context")]
524+
public SessionResumeDataContext? Context { get; set; }
517525
}
518526

519527
public partial class SessionErrorData
@@ -969,6 +977,42 @@ public partial class SystemMessageData
969977
public SystemMessageDataMetadata? Metadata { get; set; }
970978
}
971979

980+
public partial class SessionStartDataContext
981+
{
982+
[JsonPropertyName("cwd")]
983+
public string Cwd { get; set; }
984+
985+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
986+
[JsonPropertyName("gitRoot")]
987+
public string GitRoot { get; set; }
988+
989+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
990+
[JsonPropertyName("repository")]
991+
public string Repository { get; set; }
992+
993+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
994+
[JsonPropertyName("branch")]
995+
public string Branch { get; set; }
996+
}
997+
998+
public partial class SessionResumeDataContext
999+
{
1000+
[JsonPropertyName("cwd")]
1001+
public string Cwd { get; set; }
1002+
1003+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
1004+
[JsonPropertyName("gitRoot")]
1005+
public string GitRoot { get; set; }
1006+
1007+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
1008+
[JsonPropertyName("repository")]
1009+
public string Repository { get; set; }
1010+
1011+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
1012+
[JsonPropertyName("branch")]
1013+
public string Branch { get; set; }
1014+
}
1015+
9721016
public partial class SessionHandoffDataRepository
9731017
{
9741018
[JsonPropertyName("owner")]
@@ -1017,6 +1061,10 @@ public partial class AssistantMessageDataToolRequestsItem
10171061
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
10181062
[JsonPropertyName("arguments")]
10191063
public object Arguments { get; set; }
1064+
1065+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
1066+
[JsonPropertyName("type")]
1067+
public AssistantMessageDataToolRequestsItemType? Type { get; set; }
10201068
}
10211069

10221070
public partial class ToolExecutionCompleteDataResult
@@ -1068,6 +1116,12 @@ public enum UserMessageDataAttachmentsItemType
10681116
Directory,
10691117
}
10701118

1119+
public enum AssistantMessageDataToolRequestsItemType
1120+
{
1121+
Function,
1122+
Custom,
1123+
}
1124+
10711125
public enum SystemMessageDataRole
10721126
{
10731127
System,

go/generated/session_events.go

Lines changed: 42 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

nodejs/package-lock.json

Lines changed: 28 additions & 28 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

nodejs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"author": "GitHub",
4141
"license": "MIT",
4242
"dependencies": {
43-
"@github/copilot": "^0.0.384",
43+
"@github/copilot": "^0.0.387",
4444
"vscode-jsonrpc": "^8.2.1",
4545
"zod": "^4.3.5"
4646
},

nodejs/src/generated/session-events.ts

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
*
44
* Generated from: @github/copilot/session-events.schema.json
55
* Generated by: scripts/generate-session-types.ts
6-
* Generated at: 2026-01-16T00:52:51.450Z
6+
* Generated at: 2026-01-20T04:18:06.227Z
77
*
88
* To update these types:
99
* 1. Update the schema in copilot-agent-runtime
@@ -24,6 +24,12 @@ export type SessionEvent =
2424
copilotVersion: string;
2525
startTime: string;
2626
selectedModel?: string;
27+
context?: {
28+
cwd: string;
29+
gitRoot?: string;
30+
repository?: string;
31+
branch?: string;
32+
};
2733
};
2834
}
2935
| {
@@ -35,6 +41,12 @@ export type SessionEvent =
3541
data: {
3642
resumeTime: string;
3743
eventCount: number;
44+
context?: {
45+
cwd: string;
46+
gitRoot?: string;
47+
repository?: string;
48+
branch?: string;
49+
};
3850
};
3951
}
4052
| {
@@ -237,6 +249,7 @@ export type SessionEvent =
237249
toolCallId: string;
238250
name: string;
239251
arguments?: unknown;
252+
type?: "function" | "custom";
240253
}[];
241254
parentToolCallId?: string;
242255
};

0 commit comments

Comments
 (0)