Skip to content

Commit ec3efcb

Browse files
committed
chore: document the GitHub text-limit helper and brace the scale plan assertion
1 parent ed6f665 commit ec3efcb

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

‎apps/sim/lib/knowledge/__integration__/scale.integration.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,8 +374,9 @@ describe.skipIf(!enabled)('knowledge scale: isolated real PostgreSQL, no provide
374374
*/
375375
const walkIndexes = new Set(planIndexNames('reconciliation.window.scan'))
376376
expect(walkIndexes.size).toBeGreaterThan(0)
377-
for (const name of walkIndexes)
377+
for (const name of walkIndexes) {
378378
expect(['doc_connector_reconciliation_v2_idx', 'document_pkey']).toContain(name)
379+
}
379380
const [removed] = await db.execute(
380381
sql`SELECT count(*)::int AS count FROM document WHERE connector_id = ${ids.connectorId} AND external_id::integer > ${rows - absentCount} AND deleted_at IS NOT NULL AND cardinality(acl) = 0`
381382
)

‎apps/sim/lib/sim-search/live/github.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,9 @@ function groupGitHubText(query: string): string {
173173
return [text ? `(${text})` : '', ...qualifiers].filter(Boolean).join(' ')
174174
}
175175

176-
/** GitHub rejects more than 256 characters of search text; qualifiers do not count toward it. */
177176
const GITHUB_TEXT_CHARACTERS = 256
177+
178+
/** Whether a query's search text exceeds GitHub's 256-character limit; qualifiers do not count toward it. */
178179
export const exceedsGitHubTextLimit = (query: string) =>
179180
githubTokens(query)
180181
.filter((token) => !GITHUB_QUALIFIER.test(token))

0 commit comments

Comments
 (0)