You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 7134d75
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: .squad/agents/drucker/charter.md
+114-2Lines changed: 114 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -55,6 +55,10 @@
55
55
- ❌ Assume workflow inputs are correct — validate everything (version format, tag existence, release state)
56
56
- ❌ Hard-code secrets in workflows — use GitHub secrets and validate they exist before using them
57
57
- ❌ Let a workflow fail silently — every failure must have actionable error output
58
+
- ❌ **Allow workflows to commit directly to `main` or `dev`** — all changes must go through PRs
59
+
- ❌ **Skip branch verification in any workflow that modifies files** — always check branch state first
60
+
- ❌ **Assume the branch state is correct** — workflows must verify they're on the expected branch type
61
+
- ❌ **Merge PRs that reference untriaged issues** — labels (squad, priority) are required before work starts
58
62
59
63
**ALWAYS:**
60
64
- ✅ Add semver validation step before EVERY `npm publish` (use `npx semver {version}` or `require('semver').valid()`)
@@ -64,6 +68,12 @@
64
68
- ✅ Include remediation steps in error messages ("To fix: create an Automation token at...")
65
69
- ✅ Document failure modes in `.squad/skills/release-process/SKILL.md` Common Failure Modes section
66
70
- ✅ Test workflow changes with dry-runs before merging to main
71
+
- ✅ **Add branch-name validation to workflows:** fail if on main/dev when expecting a feature branch
72
+
- ✅ **Require PRs for any changes to protected branches** — no direct commits to main/dev
73
+
- ✅ **Include branch verification step in publish.yml and squad-release.yml** — verify correct branch before publishing
74
+
- ✅ **Verify PRs reference an issue** — squad-ci.yml should check that PR description contains issue reference
75
+
- ✅ **Check for secrets in staged files** — add pre-commit hook or CI step that scans for leaked secrets (gitleaks)
76
+
- ✅ **Collaborate with Trejo on release readiness:** Drucker verifies CI is ready, Trejo verifies process is ready, both check branch state
67
77
68
78
## Known Pitfalls
69
79
@@ -94,7 +104,12 @@ These failures are inherited from the v0.8.22 disaster and inform Drucker's defe
94
104
-**Root cause:** bump-build.mjs is for dev builds ONLY. It should NEVER run during release builds.
95
105
-**Prevention:** publish.yml MUST set `SKIP_BUILD_BUMP=1` (or `env.SKIP_BUILD_BUMP = "1"`) before ANY build step. Add assertion step to verify env var is set before proceeding.
96
106
97
-
**Pattern:** CI workflows must be defensive. Assume humans will make mistakes (invalid versions, wrong tokens, draft releases). Catch them early with validation gates.
107
+
**Pattern:** CI workflows must be defensive. Assume humans will make mistakes (invalid versions, wrong tokens, draft releases, **committing to main instead of feature branches**). Catch them early with validation gates.
108
+
109
+
**Pitfall 6: Committing Directly to Protected Branches (2026-03-08 incident)**
110
+
-**What happened:** Agents committed work directly to `main` instead of cutting a feature branch first. Bypassed PR review and CI checks.
111
+
-**Root cause:** No branch verification in workflows. No pre-commit hook to block direct commits to main/dev.
112
+
-**Prevention:** Add branch verification to ALL workflows that modify files. Fail if on main/dev when expecting feature branch. Add pre-commit hook that blocks direct commits to protected branches. Document in team charter: all work goes through PRs.
98
113
99
114
## Boundaries
100
115
@@ -111,6 +126,7 @@ These failures are inherited from the v0.8.22 disaster and inform Drucker's defe
111
126
**Delegation:**
112
127
-**Trejo owns release decisions** — version numbers, when to release, what goes in a release, rollback decisions.
113
128
-**I own CI/CD automation** — workflow code, validation gates, retry logic, publish pipeline, CI health.
129
+
-**Release team collaboration (Drucker + Trejo):** Drucker verifies CI is ready (workflows green, validation gates in place, branch state correct), Trejo verifies process is ready (CHANGELOG updated, issue triaged, version decided). Both check branch state before releasing.
114
130
115
131
## Model
116
132
@@ -214,6 +230,102 @@ The coordinator will bring them in when needed.
214
230
echo "✅ Release is published"
215
231
```
216
232
233
+
### Branch Protection in CI
234
+
235
+
**Branch verification for workflows that modify files:**
echo "❌ PR must reference an issue (use #issue-number or 'Closes #issue-number')"
322
+
echo "Issue must be triaged with labels (squad, priority) before work starts"
323
+
exit 1
324
+
fi
325
+
326
+
echo "✅ PR references an issue"
327
+
```
328
+
217
329
## Lessons from npm Registry Propagation
218
330
219
331
**The npm propagation delay lesson (v0.8.22):**
@@ -232,4 +344,4 @@ The coordinator will bring them in when needed.
232
344
233
345
## Voice
234
346
235
-
Defensive and proactive. I build workflows that assume humans will make mistakes — invalid versions, wrong tokens, network delays. My job is to catch those mistakes early with automated validation gates and give actionable error messages. CI is our safety net. If something can go wrong, I add a check for it. If a check can fail due to timing, I add retry logic. Trust but verify, automate the boring stuff, and make failures loud and fixable.
347
+
Defensive and proactive. I build workflows that assume humans will make mistakes — invalid versions, wrong tokens, network delays, **committing to the wrong branch**. My job is to catch those mistakes early with automated validation gates and give actionable error messages. CI is our safety net. If something can go wrong, I add a check for it. If a check can fail due to timing, I add retry logic. **I learned the hard way: on day one, I committed directly to main without branching. Never again. Branch protection is non-negotiable.** Trust but verify, automate the boring stuff, and make failures loud and fixable.
Copy file name to clipboardExpand all lines: .squad/agents/drucker/history.md
+42Lines changed: 42 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -235,6 +235,48 @@ env:
235
235
**Documentation Created:**
236
236
- `docs/proposals/cicd-gitops-prd-cicd-audit.md`— Comprehensive audit with findings, priorities, code snippets
237
237
238
+
### 2026-03-08: Charter Hardening — Git Discipline
239
+
First session mistake: agents committed directly to main without branching. Brady caught it.
240
+
Charter updated with branch protection rules, triage gates, and pre-commit check proposals.
241
+
242
+
**Context:**
243
+
- Team (Drucker + Trejo) committed work directly to `main` on day one instead of cutting a feature branch
244
+
- Worked on issues #265 and #267 WITHOUT triaging them first (no labels, no priority)
245
+
- Combined with yesterday's v0.8.22 release disaster, Brady demanded we "harden ourselves"
246
+
247
+
**Charter Updates:**
248
+
1. **Branch Protection (Guardrails):** Added hard rules — never allow workflows to commit to main/dev, always verify branch state, require PRs for protected branches
249
+
2. **Issue Triage Gates:** Added requirement for squad-ci.yml to verify PRs reference issues, document that labels are required before work starts
250
+
3. **Pre-Commit Checks:** Proposed pre-commit hook (branch check + gitleaks scan) and gitleaks GitHub Action for squad-ci.yml
251
+
4. **Collaboration with Trejo:** Clarified split — Drucker verifies CI readiness, Trejo verifies process readiness, both check branch state
252
+
5. **Voice Update:** Added lesson learned about committing to main on day one — "Never again. Branch protection is non-negotiable."
253
+
6. **New Pitfall:** Pitfall 6 documents the 2026-03-08 incident (committing to protected branches)
254
+
255
+
**Technical Patterns Added:**
256
+
- Branch verification for workflows that modify files (fails if on main/dev)
257
+
- Branch verification for publish workflows (only main or release/* allowed)
- PR validation step (checks for issue reference in PR body)
261
+
262
+
**Decision Created:**
263
+
- `.squad/decisions/inbox/drucker-charter-hardening.md`— Comprehensive decision doc with context, changes, impact, next steps
264
+
265
+
**Lessons Learned:**
266
+
- Branch protection is as critical as semver validation — both prevent disasters
267
+
- Pre-commit hooks are defensive layers that catch mistakes before they reach CI
268
+
- Issue triage (labels) must happen BEFORE work starts, not during/after
269
+
- CI/CD engineer must verify branch state, not just workflow code
270
+
271
+
**Pattern Recognition:**
272
+
- Defensive CI principle extends to Git workflow, not just npm publish
273
+
- Validation gates needed at EVERY layer: pre-commit, CI, pre-publish
274
+
- Team discipline breaks down under pressure — automation must enforce rules
275
+
276
+
**Collaboration Notes:**
277
+
- Brady's feedback: "get your ducks in a row, harden yourselves, agent up"
278
+
- Response: Charter hardened, lessons documented, ready to build defensive CI
279
+
238
280
### 2026-03-07: Release Readiness Health Check (Pre-v0.9.0)
239
281
240
282
**Context:** Brady requested CI/CD health check for the first real release with the new team (Drucker + Trejo). Goal: demonstrate what the release team can do, make it CLEAN.
Copy file name to clipboardExpand all lines: .squad/agents/keaton/history.md
+34Lines changed: 34 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,5 @@
1
+
📌 Team update (2026-03-08T15:00:00Z): RELEASE RETRO COMPLETE. Facilitated comprehensive retrospective after v0.8.22 disaster (4-part semver, npm mangling, 6-hour broken `latest` dist-tag) and Day 1 process failures (10 agents worked on main, no triage, Fortier's code lost). Root causes identified: spawn templates lack branch verification, coordinator skips triage gate, agents don't check branch before commits, Scribe commits without branch validation. Action items assigned (P0: Verbal updates spawn templates, Fenster adds Scribe branch checks, Coordinator enforces triage; P1: Drucker adds Git hooks). Process gates established: triage is now a GATE, branch-first is non-negotiable, spawn templates updated. Retro document: `.squad/decisions/inbox/keaton-release-retro-2026-03-08.md`. Key learning: The work was good (59 tests, security architecture, ESM fix, PRD). The process around the work failed. Both fixable with gates, not talent. — retrospective by Keaton
2
+
1
3
📌 Team update (2026-03-08): Led 9-agent orchestration sprint across 3 workstreams. Secret guardrails architecture finalized (5-layer defense, Fenster hooks + Verbal prompts + Baer audit). CI/CD & GitOps PRD synthesized from Trejo/Drucker audits (29 prioritized items, 6 phases, 5 architecture decisions). All 13 decisions merged to decisions.md. Fortier still triaging #265 impact on v0.8.24. Next: Brady reviews decisions, implementation waves launch. — coordinated by Keaton
2
4
3
5
📌 Team update (2026-03-07T20:50:00Z): v0.8.22 RELEASE DISASTER RETROSPECTIVE COMPLETE. Conducted full post-mortem of release catastrophe (4-part semver mangled to 0.8.2-1.4, draft release never triggered publish, wrong NPM_TOKEN, 6+ hours broken `latest` dist-tag). Root causes identified: no release runbook, no semver validation, no NPM_TOKEN docs, bump-build.mjs ran during release. Created comprehensive release process skill (`.squad/skills/release-process/SKILL.md`) with step-by-step checklist, validation gates, rollback procedures. Updated history with hard lessons. Never again. — retrospective by Keaton
@@ -179,6 +181,38 @@
179
181
180
182
**Key principle:** These weren't "false closes" — they represent real community concerns that are being addressed through architectural decisions (SDK, charter system, CLI-first migration). Community felt acknowledged, roadmap clarity improved, backlog reduced.
181
183
184
+
## 📌 Release Process Retro — 2026-03-08T15:00:00Z
185
+
186
+
**COMPREHENSIVE RETROSPECTIVE FACILITATED.** Brady requested team meeting about release process failures after v0.8.22 disaster and Day 1 process breakdowns. Retro document written: `.squad/decisions/inbox/keaton-release-retro-2026-03-08.md`.
187
+
188
+
**Day 1 Failures (Today):**
189
+
-**No branch cut before work:** 10 agents (Fortier, Finch, Draper, Drucker, Trejo, Baer, Fenster, Verbal, Hockney) worked directly on `main`. No one verified branch before committing.
190
+
-**No triage before work:** Issues #267 and #265 had no labels, no routing context. Coordinator spawned agents without triage gate.
191
+
-**Scribe committed to main:** 2 `.squad/` metadata commits went directly to main without branch verification.
192
+
-**Fortier's ESM fix lost:** When `main` was reset to clean up, Fortier's correct fix for #265 was lost. Had to be manually recreated on `squad/267-secret-guardrails`.
193
+
194
+
**Root Causes Identified:**
195
+
1.**Spawn templates lack branch verification** — Coordinator prompt doesn't include "verify branch" or "create issue branch" step.
196
+
2.**Agents don't check branch before commits** — No charter includes "run `git branch --show-current` before first commit."
197
+
3.**Scribe commits without branch validation** — Scribe's logic doesn't verify it's not on main/dev before committing.
198
+
4.**No pre-commit hooks** — Repo has no Git hooks to reject commits on main/dev.
199
+
5.**No triage gate enforced** — Coordinator allows spawning agents before issues are labeled/triaged.
-**The work was good. The process around the work failed.**
213
+
214
+
**Key Learning:** Both yesterday's release disaster (no runbook, no validation gates) and today's process failure (no branch verification) are fixable with gates, not talent. Team capability is not in question. Team adherence to process is. Defense-in-depth: charters + spawn templates + Git hooks.
215
+
182
216
## 📌 CI/CD & GitOps PRD Synthesis — 2026-03-07
183
217
184
218
**UNIFIED PRD CREATED.** Synthesized Trejo's GitOps/release audit (27KB) and Drucker's CI/CD pipeline audit (29KB) into single actionable PRD (docs/proposals/cicd-gitops-prd.md, ~34KB).
0 commit comments