-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Description
Currently search doesn't support the advanced_search parameter when searching issues. This can cause incorrect or no results to be returned when performing complex search queries.
For example, by default the GitHub API interprets spaces as OR, so the following search query returns all issues in a repository:
repo:org/name created:>2025-11-01 created:<=2025-11-30
Wrapping the dates in parentheses and explicitly defining AND fixes it when calling the API directly:
repo:org/name (created:>2025-11-01 AND created:<=2025-11-30)
However this is encoded in a way the default search is unable to handle, leading to no results being returned:
repo%3Aowner%2Fname+type%3Aissue+i%28created%3A%3E2025-11-01+AND+created%3A%3C%3D2025-11-30%29
This can be resolved by changing URI encoding on greater than and less than to HTML encoding:
repo%3Aowner%2Fname+type%3Aissue+i%28created%3A>2025-11-01+AND+created%3A<%3D2025-11-30%29
However this will likely break other functionality.
Advanced search via API was introduced by GitHub on 6 March 2025 which interprets spaces as AND by default and fixes the original query without the need for additional parameters. To enable advanced search functionality, &advanced_search=true needs to be appended to the end of the issue search URL.