Skip to content

Commit 55738fe

Browse files
lu-zeroclaude
andcommitted
fix(mcp): pass tool name and args to permission ask
Fixes anomalyco#19549 Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
1 parent 25cb2be commit 55738fe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎packages/opencode/src/session/tools.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export const resolve = Effect.fn("SessionTools.resolve")(function* (input: {
131131
{ args },
132132
)
133133
const result: Awaited<ReturnType<NonNullable<typeof execute>>> = yield* Effect.gen(function* () {
134-
yield* ctx.ask({ permission: key, metadata: {}, patterns: ["*"], always: ["*"] })
134+
yield* ctx.ask({ permission: key, metadata: args, patterns: [key], always: [key] })
135135
return yield* Effect.promise(() => execute(args, opts))
136136
}).pipe(
137137
Effect.withSpan("Tool.execute", {

0 commit comments

Comments
 (0)