Summary
add_comment_to_pending_review used mapstructure.WeakDecode to parse parameters, which silently zero-valued missing required arguments (e.g. a missing owner would become the empty string ""). This caused the GraphQL query to run with zero values rather than returning a clear validation error.
Fix: replace WeakDecode with explicit RequiredParam[string] / RequiredInt calls for owner, repo, pullNumber, path, body, and subjectType. Missing arguments now return an isError tool result with a descriptive message before any API call is made.
Upstream reference
Fork conflict
None. The fork does not modify add_comment_to_pending_review.
Context
Agents calling this tool without all required parameters would receive opaque GraphQL errors (or partial results) instead of actionable validation feedback. Returning isError: true with a clear message lets the agent self-correct on the next invocation.
Summary
add_comment_to_pending_reviewusedmapstructure.WeakDecodeto parse parameters, which silently zero-valued missing required arguments (e.g. a missingownerwould become the empty string""). This caused the GraphQL query to run with zero values rather than returning a clear validation error.Fix: replace
WeakDecodewith explicitRequiredParam[string]/RequiredIntcalls forowner,repo,pullNumber,path,body, andsubjectType. Missing arguments now return anisErrortool result with a descriptive message before any API call is made.Upstream reference
Fork conflict
None. The fork does not modify
add_comment_to_pending_review.Context
Agents calling this tool without all required parameters would receive opaque GraphQL errors (or partial results) instead of actionable validation feedback. Returning
isError: truewith a clear message lets the agent self-correct on the next invocation.