Commit a4e4d2d
* fix(rest): state the org partition on the /meta/diagnostics ?type= sweep
`GET /api/v1/meta/diagnostics` never supplied an `organizationId`, so an
organization's own overlays were absent from the Studio governance sweep —
clean tiles over a partition it never read. `getMetaDiagnostics` already
declares and reads the member; the gap was entirely at the REST call site.
The `?type=` arm now resolves the memoised exec ctx and passes the
registry-gated `organizationIdForMetaRead(canonicalMetaUrlType(type), …)`,
matching the five sibling call sites in this file.
The untyped whole-registry sweep is left env-wide on purpose and the reason
is recorded at the call site: it spans types with different
`allowOrgOverride` while the request carries one `organizationId`, and
`getMetaItems` applies no registry gate of its own — so a tenant named there
would union pre-#6190 phantom rows into a governance report.
`GET /meta/:type/:name/references` is likewise left unchanged with its
measurement recorded in place: `req.params.type` is the TARGET, while
`findReferencesToMeta` spends the organization on the SOURCE types it
sweeps, so no value this call site can pass expresses the correct scope.
Pins extend the existing meta read org-scope harness, including the
phantom-row control that discriminates the registry-gated predicate from a
raw tenant id, and the recorded gap on the untyped arm.
Part of #13753
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016yfqQh2dBgPAymYd7xipza
* chore(docs): re-anchor the system-context census after the rest-server edit
`node scripts/check-system-context-census.mjs --fix` — five `ctx.isSystem`
anchors on the permissions page moved because the diagnostics call site grew.
Pure line rot; no elevation behaviour changed. The gate reads OK afterwards:
109 elevation read sites in 20 packages across 45 files, all anchored.
Part of #13753
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016yfqQh2dBgPAymYd7xipza
* refactor(rest): resolve the diagnostics exec ctx in the house spelling, and count it
Two coupled corrections found by running the package suite:
1. `execctx-consumer-census` counts every `this.resolveExecCtx(environmentId,
req)` site in this file and pins the totals. The diagnostics door adds one,
so 75 -> 76 sites, 95 -> 97 mentions (one call site plus one prose mention),
22 -> 23 locally caught. The bare/inline splits are unchanged.
2. The site is now resolved inside an `if (diagnosticsType)` block instead of a
ternary. A ternary puts `.catch(rethrowAuthzStoreUnavailable)` on a
continuation line with no trailing `;`, which is a THIRD layout the census's
`catchArguments()` reader cannot see — it counted 23 caught sites and found
22 arguments, reddening the section 7 CONTROL that exists precisely so a
reader which stops matching cannot look like a clean pass. Conforming to the
spelling the sibling doors already use was preferred over teaching the
reader a new layout.
Part of #13753
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016yfqQh2dBgPAymYd7xipza
* chore(docs): re-anchor the system-context census after the call-site reshape
`check-system-context-census.mjs --fix` again — the same five `ctx.isSystem`
anchors moved by 3 lines when the diagnostics exec-ctx resolution became a
statement. Pure line rot; the gate reads OK afterwards.
Part of #13753
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016yfqQh2dBgPAymYd7xipza
* regen: re-anchor the system-context census on the merged tree
pnpm gen:system-context-census, run after the merge commit. Row 50's five
rest-server.ts citations move back to the branch's positions (the branch adds
lines above them); rows 48/49 keep main's action-execution.ts anchors. Neither
side's numbers were correct for the merged tree, which is why this is
regenerated rather than hand-resolved.
check-system-context-census: OK — 109 elevation read sites in 20 packages
across 45 files, all anchored; 145 anchors resolve, 27 declared non-read.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016yfqQh2dBgPAymYd7xipza
* chore(docs): re-anchor the system-context census from the merged tree
`pnpm gen:system-context-census` re-derived row 50's five `rest-server.ts`
citations after merging `origin/main`. Neither side's numbers were right for
the merged tree, which is why this file is regenerated and never hand-resolved.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016yfqQh2dBgPAymYd7xipza
---------
Co-authored-by: Claude <noreply@anthropic.com>
1 parent ba4587a commit a4e4d2d
5 files changed
Lines changed: 391 additions & 8 deletions
File tree
- .changeset
- content/docs/permissions
- packages/rest/src
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
158 | 158 | | |
159 | 159 | | |
160 | 160 | | |
161 | | - | |
| 161 | + | |
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
309 | 309 | | |
310 | 310 | | |
311 | 311 | | |
312 | | - | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
313 | 334 | | |
314 | 335 | | |
315 | 336 | | |
| |||
340 | 361 | | |
341 | 362 | | |
342 | 363 | | |
343 | | - | |
344 | | - | |
| 364 | + | |
| 365 | + | |
345 | 366 | | |
346 | 367 | | |
347 | | - | |
| 368 | + | |
348 | 369 | | |
349 | 370 | | |
350 | 371 | | |
| |||
354 | 375 | | |
355 | 376 | | |
356 | 377 | | |
357 | | - | |
| 378 | + | |
358 | 379 | | |
359 | 380 | | |
360 | 381 | | |
361 | 382 | | |
362 | | - | |
| 383 | + | |
363 | 384 | | |
364 | 385 | | |
365 | 386 | | |
| |||
Lines changed: 216 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
338 | 338 | | |
339 | 339 | | |
340 | 340 | | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
341 | 344 | | |
342 | 345 | | |
343 | 346 | | |
| |||
555 | 558 | | |
556 | 559 | | |
557 | 560 | | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
| 642 | + | |
| 643 | + | |
| 644 | + | |
| 645 | + | |
| 646 | + | |
| 647 | + | |
| 648 | + | |
| 649 | + | |
| 650 | + | |
| 651 | + | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
| 688 | + | |
| 689 | + | |
| 690 | + | |
| 691 | + | |
| 692 | + | |
| 693 | + | |
| 694 | + | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
| 717 | + | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
| 727 | + | |
| 728 | + | |
| 729 | + | |
| 730 | + | |
| 731 | + | |
| 732 | + | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
| 738 | + | |
| 739 | + | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
| 756 | + | |
| 757 | + | |
| 758 | + | |
| 759 | + | |
| 760 | + | |
| 761 | + | |
| 762 | + | |
| 763 | + | |
| 764 | + | |
| 765 | + | |
| 766 | + | |
| 767 | + | |
| 768 | + | |
| 769 | + | |
| 770 | + | |
| 771 | + | |
| 772 | + | |
| 773 | + | |
0 commit comments