Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(claude): approval cards close when Claude withdraws the request #27320

Mergedashx-j(GitHub profile, opens in a new tab)merged 3 commits intomain fromrefs/pull/27320/headmerged by maria-rcks View on GitHub

Showing 2 changed files with 126 additions and 0 deletions.

x
0 of 2 viewed, 2 left
90 additions and 0 deletionsapps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.test.tsModified
View file
@@ -9044,6 +9044,96 @@
+ it.effect.each([
+ { card: "an approval", toolName: "Bash", toolInput: { command: "echo probe" } },
+ {
+ card: "a question",
+ toolName: "AskUserQuestion",
+ toolInput: {
+ questions: [
+ {
+ header: "Target",
+ question: "Where should this deploy?",
+ options: [
+ { label: "Production", description: "Deploy to production." },
+ { label: "Staging", description: "Deploy to staging." },
+ ],
+ multiSelect: false,
+ },
+ ],
+ },
+ },
+ ])("closes $card card when Claude withdraws its request", ({ toolName, toolInput }) =>
+ Effect.scoped(
+ Effect.gen(function* () {
+ const harness = yield* makeWakeHarness;
+ yield* harness.runtime.startTurn(
+ makeClaudeTestTurnInput({
+ threadId: harness.threadId,