tools: replace active_only with include_inactive in search_members#99
Merged
Conversation
Replace the ActiveOnly *bool field (which defaulted to true via nil check) with IncludeInactive bool. The zero value now correctly expresses the default — Active memberships only — without requiring a pointer or nil sentinel. Update the tool description and jsonschema tag to name example non-Active statuses (Purchased, Expired, Completed) so callers know what they are opting into. Assisted-by: github-copilot:claude-sonnet-4.6 Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the search_members MCP tool argument contract to use a non-pointer boolean (include_inactive) instead of a *bool sentinel (active_only), making the default behavior (“Active-only”) naturally represented by the zero value while keeping the implementation and tool documentation aligned.
Changes:
- Replaced
SearchMembersArgs.ActiveOnly *boolwithSearchMembersArgs.IncludeInactive bool. - Simplified the status filter logic in
handleSearchMembersto applystatus:Activeunlessinclude_inactive=true. - Updated the tool description and
jsonschematag text to clarify which non-Active statuses may be included.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Replace the
ActiveOnly *boolfield (which defaulted totruevia a nil-pointer check) withIncludeInactive bool. The zero value now correctly expresses the default — Active memberships only — without requiring a pointer or nil sentinel.The tool description and
jsonschematag are updated to name example non-Active statuses (Purchased,Expired,Completed) so callers know what they are opting into when settinginclude_inactive=true.Non-breaking change:
active_onlywas introduced in v0.10.0, which has not yet been released to production, so no callers depend on it.Changes
SearchMembersArgs:ActiveOnly *bool→IncludeInactive boolhandleSearchMembers: filter logic simplified from nil-check to!args.IncludeInactive🤖 Generated with GitHub Copilot (via OpenCode)