docs(tasks): trim the search-window error pattern comment (#12130)

Keeps only the non-obvious rationale for pinning GitHub's free-text 422 wording.

Co-authored-by: Orca <help@stably.ai>
This commit is contained in:
Jinjing 2026-08-02 12:14:12 -07:00 committed by GitHub
parent 56ab5fd1dc
commit 99b94a38eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 7 deletions

View File

@ -3,13 +3,8 @@ import { isClipboardTextByteLengthOverLimit } from './clipboard-text'
export const GITHUB_WORK_ITEMS_QUERY_MAX_BYTES = 8 * 1024
/**
* GitHub's Search API only pages through the first 1000 matches; beyond that it
* 422s with "Only the first 1000 search results are available". Matching that
* free-text wording is the ONLY signal separating a permanently unreachable page
* from a transient failure (#11485), so the phrase is pinned here rather than
* inlined: if GitHub rewords it, window 422s silently demote to generic
* failures and the advertised page count stops being capped.
* `gh-utils.test.ts` asserts the classified message still carries this phrase.
* The Search API's free-text 422 wording is the only signal separating a
* permanently unreachable page (past the first 1000 matches) from a transient failure.
*/
export const GITHUB_SEARCH_RESULT_WINDOW_ERROR_PATTERN = /first 1000 search results/i