Commit f41664f
fix(sources): paginate github issues on the gateway raw page length (#176)
fix(sources): paginate github issues on the gateway's raw page length
The OC list_repository_issues action filters pull requests out AFTER
paginating, so the filtered issues array's length is not a termination
signal: short-page termination silently truncated the scan on the first
PR-bearing page, and even empty-page termination fails on 100
consecutive PRs. Upstream now reports the raw page length
(pageInfo.fetched, oomol-lab/open-connector#228); this change consumes
it.
Engine: PageNumber gains raw_page_size_path, mirroring
total_pages_path — when declared, the scan continues while the RAW page
was full regardless of how short (or empty) the filtered rows are; a
missing signal propagates as RowPathNotFound and a non-integer one
fails as the new PaginationRawPageSizeInvalid (kind-only), never a
silent truncation. The two authoritative signals are mutually exclusive
at validate time. Loader exposes raw_page_size_path on page_number
pagination; the issues table declares $.pageInfo.fetched.
Contract re-captured from a live gateway carrying the upstream fix
(outputSchema now declares pageInfo) and the fingerprint re-pinned, so
older gateways fail issues registration at the fingerprint gate instead
of truncating. Live-verified: all 11 tables register with the new pin
and the issues scan reaches the credential wall.
Tests: engine units (continue on full raw page with short/empty rows,
terminate on short raw page, missing/invalid signal failures, total/raw
mutual exclusion) and a pack e2e driving a 3-page scan whose middle
page is ALL pull requests — the case that defeats every filtered-count
heuristic. Stubs and the demo stub gateway now emit pageInfo. Docs and
spec updated with the minimum-gateway note. 246 open_connector / 803
lib tests green.
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>1 parent 33033a3 commit f41664f
9 files changed
Lines changed: 280 additions & 23 deletions
File tree
- crates/skardi/src/sources/providers/open_connector
- packs
- fixtures/github/contracts
- docs
- open-connector
- superpowers/specs
Lines changed: 13 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
233 | 246 | | |
234 | 247 | | |
235 | 248 | | |
| |||
Lines changed: 16 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
126 | 141 | | |
127 | 142 | | |
128 | 143 | | |
129 | | - | |
| 144 | + | |
Lines changed: 74 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | | - | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
12 | 19 | | |
13 | 20 | | |
14 | 21 | | |
| |||
115 | 122 | | |
116 | 123 | | |
117 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
118 | 168 | | |
119 | 169 | | |
120 | 170 | | |
| |||
623 | 673 | | |
624 | 674 | | |
625 | 675 | | |
626 | | - | |
| 676 | + | |
627 | 677 | | |
628 | 678 | | |
629 | 679 | | |
630 | 680 | | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
631 | 684 | | |
632 | 685 | | |
633 | | - | |
| 686 | + | |
634 | 687 | | |
635 | | - | |
| 688 | + | |
| 689 | + | |
| 690 | + | |
| 691 | + | |
| 692 | + | |
| 693 | + | |
636 | 694 | | |
637 | 695 | | |
638 | 696 | | |
| |||
658 | 716 | | |
659 | 717 | | |
660 | 718 | | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
661 | 727 | | |
662 | 728 | | |
663 | 729 | | |
| |||
1356 | 1422 | | |
1357 | 1423 | | |
1358 | 1424 | | |
1359 | | - | |
| 1425 | + | |
| 1426 | + | |
| 1427 | + | |
1360 | 1428 | | |
1361 | 1429 | | |
1362 | 1430 | | |
| |||
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
45 | 49 | | |
46 | 50 | | |
47 | 51 | | |
| |||
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
400 | 400 | | |
401 | 401 | | |
402 | 402 | | |
| 403 | + | |
| 404 | + | |
403 | 405 | | |
404 | 406 | | |
405 | 407 | | |
| |||
418 | 420 | | |
419 | 421 | | |
420 | 422 | | |
| 423 | + | |
421 | 424 | | |
422 | 425 | | |
423 | 426 | | |
424 | 427 | | |
425 | 428 | | |
| 429 | + | |
426 | 430 | | |
427 | 431 | | |
428 | 432 | | |
| |||
0 commit comments