Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Add issues type filter #579

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from
Closed

Add issues type filter #579

wants to merge 3 commits into from

Conversation

JoannaaKL
Copy link
Contributor

Add is:issue parameter to SearchIssues query.

Closes: #462

@JoannaaKL JoannaaKL marked this pull request as ready for review June 25, 2025 12:48
@Copilot Copilot AI review requested due to automatic review settings June 25, 2025 12:48
@JoannaaKL JoannaaKL requested a review from a team as a code owner June 25, 2025 12:48
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Adds a filter to ensure only issues are returned by SearchIssues and provides an end-to-end test for listing issues.

  • Append is:issue to the search query if it's not already present
  • Introduce TestListIssues E2E test to validate issue creation and retrieval

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
pkg/github/issues.go Insert is:issue into the query string when missing
e2e/e2e_test.go Add TestListIssues function to cover list_issues
Comments suppressed due to low confidence (1)

pkg/github/issues.go:195

  • Consider adding a unit test for SearchIssues to verify that it appends is:issue when missing and does not duplicate the filter if it's already present.
			if !strings.Contains(query, "is:issue") {

e2e/e2e_test.go Outdated
}

t.Logf("Creating repository %s/%s...", currentOwner, repoName)
_, err = mcpClient.CallTool(ctx, createRepoRequest)
Copy link
Preview

Copilot AI Jun 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The test ignores the response from create_repository but then asserts on resp.IsError, which is stale. Change this line to resp, err = mcpClient.CallTool(...) so you capture the actual tool response before asserting.

Suggested change
_, err = mcpClient.CallTool(ctx, createRepoRequest)
resp, err := mcpClient.CallTool(ctx, createRepoRequest)

Copilot uses AI. Check for mistakes.

@williammartin williammartin self-requested a review June 25, 2025 14:23
Copy link
Collaborator

@SamMorrowDrums SamMorrowDrums left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like we cannot do this atomically without the commensurate pull request version.

Can you add the pull request tool as a PR with this as base branch maybe?

@JoannaaKL JoannaaKL closed this Jun 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Query must include 'is:issue' or 'is:pull-request' on search_issues
2 participants