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
[MEDIUM] health rejects legacy charters and routing tables while missing built-in roster drift #2298
After upgrading existing teams to 2.0.0-preview.1, squad health produces false failures for legacy charter and routing formats, while also missing a real roster migration inconsistency:
Legacy charters with a # Name — Role heading and ## Identity / **Role:** metadata are rejected as missing identity name/role.
The routing validator parses unrelated Markdown table headers/example cells as agent names.
Upgrade creates agents/rai/ and agents/fact-checker/, but does not add Rai or Fact Checker to team.md, despite the 2.0 built-ins contract saying they are always on the roster.
Environment
Squad CLI 2.0.0-preview.1, installed from the exact published release tarball
squad upgrade
squad health --json
Get-Content .squad\team.md
Get-ChildItem .squad\agents -Directory |Select-Object-ExpandProperty Name
Run this against an existing 0.11-style team whose charters use the previously shipped heading/Identity format and whose routing.md contains multiple Markdown tables.
Observed
Health returned exit 1 with:
registry-charters: 6 charters "must declare identity name and role"
belanna, data, neelix, picard, seven, worf
It also reported 17 false unknown routing agents, including literal headers/example cells:
Route To
Examples
{Name}
Write tests
In a second upgraded team, health passed with nine roster members even though both directories existed:
.squad/agents/rai/
.squad/agents/fact-checker/
Neither Rai nor Fact Checker appeared in team.md.
Expected
Health accepts legacy charter formats that prior Squad releases generated, or upgrade migrates them before validation.
Routing validation parses only the designated routing table and ignores headers, examples, and unrelated tables.
Upgrade adds the always-on Rai and Fact Checker built-ins to team.md when it creates their agent directories.
Health flags folder/roster divergence rather than passing it.
Impact / Severity
MEDIUM. Healthy upgraded teams are reported as broken, while a genuine roster inconsistency is missed. This reduces trust in the health command and leaves built-in agents undiscoverable through roster-based routing.
Proposed fix
Accept both legacy and 2.0 charter identity schemas, with migration to the canonical form where safe.
Parse routing sections structurally instead of scanning every pipe-delimited row.
Add a roster migration for Rai and Fact Checker and a health invariant that roster and active built-in directories agree.
Add fixtures from 0.11 and 0.13 teams to upgrade/health regression tests.
Activity
fix(cli): 2.0.0-preview.2 upgrade/health fixes from dogfooding
fix(cli): 2.0.0-preview.2 upgrade/health fixes from dogfooding (#2303)