Skip to content

Commit a250a0c

Browse files
committed
fix(sdk): mirror retry status telemetry
1 parent 4611c37 commit a250a0c

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

‎packages/cli/test/cli/usage-token-breakdown.test.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,15 +163,15 @@ describe("message_complete emit block shape (source-verified, #86)", () => {
163163
describe("EVENTS.md documents token breakdown and context (#86)", () => {
164164
test("EVENTS.md message_complete section includes reasoning token field", async () => {
165165
const doc = await Bun.file(EVENTS_MD).text()
166-
const idx = doc.indexOf("message_complete")
166+
const idx = doc.indexOf("### `message_complete`")
167167
expect(idx).toBeGreaterThan(-1)
168168
const section = doc.slice(idx, idx + 1500)
169169
expect(section).toContain("reasoning")
170170
})
171171

172172
test("EVENTS.md message_complete section documents context field", async () => {
173173
const doc = await Bun.file(EVENTS_MD).text()
174-
const idx = doc.indexOf("message_complete")
174+
const idx = doc.indexOf("### `message_complete`")
175175
expect(idx).toBeGreaterThan(-1)
176176
const section = doc.slice(idx, idx + 1500)
177177
expect(section).toContain("context")

‎packages/sdk/src/gen/types.gen.ts‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -459,6 +459,12 @@ export type SessionStatus =
459459
attempt: number
460460
message: string
461461
next: number
462+
retryID?: string
463+
messageID?: string
464+
providerID?: string
465+
modelID?: string
466+
reason?: "rate_limit" | "timeout" | "network" | "provider" | "unknown"
467+
delayMs?: number
462468
}
463469
| {
464470
type: "busy"

0 commit comments

Comments
 (0)