- Notifications
You must be signed in to change notification settings - Fork899
Add optional string array param#101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Pull Request Overview
This PR introduces an optional string array parameter handling to fix an integration bug where parameters provided as []any were not properly coerced to []string.
- Introduces a new helper function optionalStringArrayParam in pkg/github/server.go.
- Adds new tests in pkg/github/server_test.go to validate the behavior of string array parameter handling.
- Updates issues related functions and tests in pkg/github/issues.go and pkg/github/issues_test.go to utilize the new helper.
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
File | Description |
---|---|
pkg/github/server_test.go | New test cases for validating optional string array parameter handling. |
pkg/github/server.go | New helper function optionalStringArrayParam with improved type checking and error messages. |
pkg/github/issues_test.go | Updated test cases to provide []any for assignees and labels. |
pkg/github/issues.go | Replaced use of generic optionalParam with optionalStringArrayParam for parameters conversion. |
Tip: If you use Visual Studio Code, you can request a review from Copilot before you push from the "Source Control" tab.Learn more
Uh oh!
There was an error while loading.Please reload this page.
baf5038
to255ba08
Compare6e132eb
intomainUh oh!
There was an error while loading.Please reload this page.
Description
Fixes an integration bug introduced in#82, where the MCP host was providing a slice that was treated as
[]any
and not coerced to[]string
.