Skip to content

Commit 80becbc

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 6d9539f commit 80becbc

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
@@ -398,7 +398,7 @@ export const resolve = Effect.fn("SessionTools.resolve")(function* (input: {
398398
{ args },
399399
)
400400
const result: Awaited<ReturnType<NonNullable<typeof execute>>> = yield* Effect.gen(function* () {
401-
yield* ctx.ask({ permission: key, metadata: {}, patterns: ["*"], always: ["*"] })
401+
yield* ctx.ask({ permission: key, metadata: args, patterns: [key], always: [key] })
402402
return yield* Effect.promise(() => execute(args, opts))
403403
}).pipe(
404404
Effect.withSpan("Tool.execute", {

0 commit comments

Comments
 (0)