authorgravatar for lucenz@proton.meSimone <lucenz@proton.me> 2026-09-04 22:48:00+02:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-09-04 16:48:00-04:00
logb7d6e65021b021207424c56cb32d6d711fd875fb
tree65d1c2bf0f8785a06f4a355c05c509d037b39b9d
parent0a590fa01af66ec135d2ebf2d5542b08a37dc275
signature Signed by PGP key B5690EEEBB952194

fix(contracts): include tool.denied in runtime event types (#9770)

Co-authored-by: Simone <185146821+Lucenx9@users.noreply.github.com>

2 files changed, 11 insertions(+), 2 deletions(-)

packages/contracts/src/providerRuntime.test.ts+10-2
......@@ -1,11 +1,19 @@
1import { describe, expect, it } from "vite-plus/test";
1import { describe, expect, expectTypeOf, it } from "vite-plus/test";
22import * as Schema from "effect/Schema";
33
4import { classifyTaskAgentKind, ProviderRuntimeEvent } from "./providerRuntime.ts";
4import {
5 classifyTaskAgentKind,
6 ProviderRuntimeEvent,
7 type ProviderRuntimeEventType,
8} from "./providerRuntime.ts";
59
610const decodeRuntimeEvent = Schema.decodeUnknownSync(ProviderRuntimeEvent);
711
812describe("ProviderRuntimeEvent", () => {
13 it("includes every runtime event in the public event type", () => {
14 expectTypeOf<ProviderRuntimeEvent["type"]>().toEqualTypeOf<ProviderRuntimeEventType>();
15 });
16
917 it("requires input and output totals for complete turn usage", () => {
1018 const completeEvent = {
1119 type: "turn.completed",
packages/contracts/src/providerRuntime.ts+1
......@@ -186,6 +186,7 @@ const ProviderRuntimeEventType = Schema.Literals([
186186 "hook.completed",
187187 "tool.progress",
188188 "tool.summary",
189 "tool.denied",
189190 "auth.status",
190191 "account.updated",
191192 "account.rate-limits.updated",