Repository navigation
Commit edf15c0
ci: route the base-std docs tree, skip deleted sources, report unrouted files (#1938)
* Route the base-std docs tree and report unrouted or removed sources
base-std#213 (be6d045) deleted the flat docs/B20, docs/PolicyRegistry and
docs/ActivationRegistry pages and added an audience-layered docs/ tree.
The route table mapped only the six deleted files, so the sync edited
their target pages from an all-minus diff (adding "source file removed"
banners to reference pages generated from an unchanged interface) and
dropped the fifteen new files without a trace (#1928).
Route table
- Retire the rules for the deleted files. Add rules for overview.md,
architecture.md, concepts/*, guides/*, reference/*, placed where
docs/ia-guidelines.md and docs/content-guidelines.md put that content:
chain-generic precompile mechanics on Base Protocol > Execution, the
B20 component map and key concepts on the specification overview,
execution and versioning guarantees on the invariants page, how-to
guides on the existing Build on Base task pages, reference tables on
the B20 supporting pages.
- New `ignored` kind for upstream scaffolding (README, guide template,
interface link index) so it stays out of the unrouted report.
Sync script
- `removed_paths`: derived by the workflow from the commit API for the
verified sha (renames count their previous name). Removed files never
route.
- `classifyChangedPaths` buckets every changed path as routed, ignored,
unrouted or removed; the PR body gains "Unrouted source files" and
"Removed source files" sections. When nothing routes, the workflow
files the report as an issue, one per source sha.
- Placement proposals: unrouted Markdown sources go through one Haiku
call that reads the IA and content guidelines plus the existing
Specifications and Build on Base page list, and names the existing
page each file belongs on with the guideline rule that decides it.
Proposals are filtered against the candidate list; nothing creates a
page. GUIDELINE_ROUTING=apply also edits the proposed pages.
- `validateCallouts` rejects Warning/Note/Info/Tip callouts that talk
about source files, restructures or "last known state"; prompt rules
10 and 11 say the same and let the sync replace a "Generated B20
reference for" placeholder description.
Tests cover the new routes against the real be6d045 file list, removed
path exclusion, classification, proposal filtering, the routing report
and the callout guard.
* Harden the routing report and removed_paths handling
Only hyperlink source paths made of plain path characters in the
routing report; anything else renders as inert code so a crafted
filename cannot close the markdown link. Cap removed_paths in the
script (200 entries, 512 bytes each) and make the workflow overwrite
the field for every non-release dispatch, so the payload can never
supply it.
---------
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>1 parent fd12749 commit edf15c0
10 files changed
Lines changed: 1046 additions & 77 deletions
File tree
- .github/workflows
- scripts
- sync-from-base-std
- __tests__
- fixtures
- llm
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
131 | 131 | | |
132 | 132 | | |
133 | 133 | | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
134 | 138 | | |
135 | 139 | | |
136 | 140 | | |
| |||
772 | 776 | | |
773 | 777 | | |
774 | 778 | | |
| 779 | + | |
| 780 | + | |
| 781 | + | |
| 782 | + | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
| 787 | + | |
| 788 | + | |
| 789 | + | |
| 790 | + | |
| 791 | + | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
775 | 838 | | |
776 | 839 | | |
777 | 840 | | |
| |||
1009 | 1072 | | |
1010 | 1073 | | |
1011 | 1074 | | |
| 1075 | + | |
| 1076 | + | |
| 1077 | + | |
| 1078 | + | |
1012 | 1079 | | |
1013 | 1080 | | |
1014 | 1081 | | |
| |||
1338 | 1405 | | |
1339 | 1406 | | |
1340 | 1407 | | |
| 1408 | + | |
| 1409 | + | |
| 1410 | + | |
| 1411 | + | |
| 1412 | + | |
| 1413 | + | |
| 1414 | + | |
| 1415 | + | |
| 1416 | + | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
| 1420 | + | |
| 1421 | + | |
| 1422 | + | |
| 1423 | + | |
| 1424 | + | |
| 1425 | + | |
| 1426 | + | |
| 1427 | + | |
| 1428 | + | |
| 1429 | + | |
| 1430 | + | |
| 1431 | + | |
| 1432 | + | |
| 1433 | + | |
| 1434 | + | |
| 1435 | + | |
| 1436 | + | |
| 1437 | + | |
| 1438 | + | |
| 1439 | + | |
| 1440 | + | |
| 1441 | + | |
| 1442 | + | |
| 1443 | + | |
| 1444 | + | |
| 1445 | + | |
| 1446 | + | |
| 1447 | + | |
| 1448 | + | |
| 1449 | + | |
| 1450 | + | |
| 1451 | + | |
| 1452 | + | |
| 1453 | + | |
| 1454 | + | |
| 1455 | + | |
| 1456 | + | |
| 1457 | + | |
| 1458 | + | |
| 1459 | + | |
| 1460 | + | |
| 1461 | + | |
| 1462 | + | |
| 1463 | + | |
| 1464 | + | |
| 1465 | + | |
| 1466 | + | |
| 1467 | + | |
| 1468 | + | |
| 1469 | + | |
| 1470 | + | |
| 1471 | + | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
| 1475 | + | |
| 1476 | + | |
| 1477 | + | |
| 1478 | + | |
| 1479 | + | |
| 1480 | + | |
| 1481 | + | |
| 1482 | + | |
| 1483 | + | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
| 1487 | + | |
| 1488 | + | |
| 1489 | + | |
| 1490 | + | |
| 1491 | + | |
| 1492 | + | |
| 1493 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
20 | 75 | | |
21 | 76 | | |
22 | 77 | | |
| |||
34 | 89 | | |
35 | 90 | | |
36 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
37 | 97 | | |
38 | 98 | | |
39 | 99 | | |
| |||
0 commit comments