GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||
GeezerVison is showing github.com — feat: PR architectural impact analysis — blast radius, module boundaries, reviewer routing · Issue #733 · github/squad Closed Labels enhancementNew feature or improvementNew feature or improvement DescriptionProblem StatementWhen a PR lands on bradygaster/squad, there's no automated way to answer:
Today this is done by human judgment reading the diff. For AI agents making changes, there's no check at all — they don't know the boundaries they're crossing. The Incident That Proves This Is NeededIssue #631:
Solution: Squad Impact — Automated PR Impact AnalysisNot a product feature. This is CI infrastructure for the Squad repo itself — a GitHub Action + reusable analysis script that runs on every PR to understand architectural impact. High-Level FlowOutputs (PR Comment)Example: PR #631 reanalyzed with this tool: ## 🔴 SQUAD IMPACT REPORT — PR #631 **Risk Tier:** CRITICAL (⚠️ Requires Lead approval before merge) ### 📦 Packages Affected (2 of 2) - **squad-sdk** — 261 files deleted - **squad-cli** — 100 files deleted ### 📁 Modules Touched (18 of 20) - `src/adapter/` — 31 files (Primary: EECOM, Secondary: CAPCOM) - `src/agents/` — 28 files (Primary: Procedures) - `src/runtime/` — 24 files (Primary: GNC) - `src/cli/` — 23 files (Primary: EECOM) - `src/tools/` — 21 files (Primary: EECOM) - ... (13 more modules) ### 💥 Impact Analysis | Metric | Value | Status | |--------|-------|--------| | Files Changed | 361 | 🔴 CRITICAL (>50) | | Modules Touched | 18 | 🔴 CRITICAL (>8) | | Boundaries Crossed | 17 | 🔴 CRITICAL | | New Dependency Edges | 12 | 🔴 HIGH | | Critical Files Touched | 8 | 🔴 YES | ### 👥 Suggested Reviewers (by module ownership) @squad/eecom (touched 5 modules) | @squad/gnc | @squad/procedures | @squad/flight (Architecture Lead - CRITICAL tier) ### 🏷️ Suggested Labels - `squad:eecom` - `squad:gnc` - `squad:procedures` - `impact:critical` - `needs:flight-review` Architecture1. GitHub Action Workflow (
|
| Source | Location | Provides |
|---|---|---|
| Module Ownership | .squad/routing.md |
20 directory → agent mappings |
| Critical File Manifest | packages/squad-cli/src/cli/core/templates.ts (TEMPLATE_MANIFEST) |
Ownership flags for critical files |
| Package Boundaries | package.json workspaces |
Package directories (packages/*) |
| TypeScript Projects | tsconfig.json + packages/*/tsconfig.json |
Project boundaries |
| Code Owners (optional) | .github/CODEOWNERS |
Human reviewer mapping |
scripts/
├── analyze-impact.mjs ← Main analysis engine
├── request-reviewers.mjs ← POST /repos/.../pulls/.../requested_reviewers
├── impact-utils/
│ ├── parse-routing.mjs ← Read & parse routing.md
│ ├── parse-manifest.mjs ← Extract TEMPLATE_MANIFEST from templates.ts
│ ├── diff-parser.mjs ← Parse `gh pr diff` output
│ └── risk-scorer.mjs ← Calculate risk tier (logic below)
│
.github/workflows/
└── squad-impact.yml ← Workflow definition (above)
Note: This is NOT a product feature export in packages/squad-sdk/. It's internal CI tooling that lives in scripts/ and .github/workflows/.
Risk tier is calculated by combining multiple factors:
| Tier | Criteria |
|---|---|
| LOW | • ≤1 module touched AND • 0 new dependency edges AND • ≤5 files changed AND • No critical files touched |
| MEDIUM | • 2–4 modules touched OR • 1 new dependency edge OR • 6–20 files changed |
| HIGH | • 5–8 modules touched OR • 2–3 new dependency edges OR • 21–50 files changed OR • Any critical file touched |
| CRITICAL | • >8 modules touched OR • >3 new dependency edges OR • >50 files changed OR • Mass deletion (>10 files deleted) OR • Cross-package with new edges OR • package.json / routing.md / .squad/* modified |
Special Cases:
scripts/analyze-impact.mjs — parse gh pr diff, map files → modules, calculate riskscripts/impact-utils/ — helper modules (routing parser, risk scorer)node scripts/analyze-impact.mjs 733.github/workflows/squad-impact.yml — trigger on PR, call script, post commentscripts/request-reviewers.mjs — auto-request reviewers based on module ownershipenvironment protection rules — block CRITICAL PRs until Lead approvesscripts/analyze-impact.mjs runs successfully on any PR diffrouting.md module→owner table.github/workflows/squad-impact.yml triggers on all PRssquad:{agent} labels based on touched modulesneeds:flight-review and/or blocked by environment rule