carlos / platform Public

parity: AGENTS.md rule and work-package discussions

Adds the parity rule to AGENTS.md beside the docs/site/cli.md rule. Files
the nine work packages as amadan discussions #734 to #742 (Feature
Request) and records their numbers in parity/packages.tsv.
TestParityPackagesFiled fails on a package with no discussion number.

Applies the Luna copy pass to the page's static prose and the AGENTS.md
text; page_test follows the new subcommand line. docs/parity.md
regenerated with make parity-doc.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev pushed by paul@keymail.dev 14dbd242a2f47e03ac286a488bcbfc64724113fa parent db2410c
6 files changed, +51 −26
  • AGENTS.md +10 −0
  • docs/parity.md +12 −12
  • internal/parity/page.go +4 −4
  • internal/parity/page_test.go +1 −1
  • internal/parity/repo_test.go +15 −0
  • parity/packages.tsv +9 −9

Intent

Human

<paseo-system version="1" kind="agent-message" source-agent-id="c352b3ff-98e2-427d-859c-088309468688" message-id="f69136f9-2f92-403e-8dc9-a37852e1b234" source-agent-title="Parity guard (slice 3): plan + build + release (controller)"> Parity guard build (design-parity-guard): stopping rule 2 on Task 2, the console routeDecls refactor. Your call needed on one fix; everything else continues. Status: Task 1 (internal/parity) and Task 3 (seeded table, 226 rows, all 198 non-cli console routes covered, page generated, census-card clean) are committed. Task 2 (420 registrations moved into routeDecls, scanners rewritten, 11 mutation checks) passed Astra&apos;s behaviour check: all 420 routes keep pattern, handler, wrapper, roles and gates. Astra approved the record-write census re-pin. Fault family &quot;registration completeness&quot; (every served route goes through registerRoute and so through claimEntries and the scanners), two rounds running: - R1 P1: a mux alias (`m := s.mux; m.HandleFunc(...)`) escaped the registrar scan. Fixed acfe4a88 (any Handle/HandleFunc outside registerRoute, any receiver, called or as a value, plus http.Handle*). - R2 P1: passing s.mux to another package&apos;s helper (e.g. instanceupdates.Mount(s.mux, ...)) still registers a route unseen. Note: the pre-branch registrar test had this same hole; it is not a regression. Findings: docs/superpowers/reviews/CODEX-FINDINGS-parity-guard-T2{,-R2}.md on the branch. Options (rule 2): A. (recommended) Enforce one boundary: in non-test internal/console code, the Server&apos;s mux field may be referenced only in registerRoute (its two HandleFunc calls), the perf.Middleware wrap in NewServer, and its construction. Any other reference (passed, aliased, replaced) fails with its location. Today there are exactly those three references, so it is ~20 lines plus a negative fixture. Cost if wrong: a future legitimate use of s.mux needs a reviewed exemption. B. Cut the claim: document that completeness covers Handle/HandleFunc in this package only, as before the branch. C. Refuse up front: no route may be added except through routeDecls, stated in AGENTS.md, no test. (Weaker than A.) I will build A unless you say otherwise, and that fix gets a scoped Astra round 3 (the last). Meanwhile I am continuing Task 4 (AGENTS.md rule, work-package discussions, Luna pass). </paseo-system>

Attributed to this commit: 7.18 g CO₂e (892,248 tokens). This is an attribution, not a measurement — usage counted from this commit's own marker forward to the next one on design-parity-guard, never backward from it. A turn that produced more than one commit books all of its tokens to the last one, and a concurrent session on this branch can add to the same figure. Some of it was priced using the shared default rate, because no model-specific factor row exists yet for at least one model involved. The Carbon view has the repo total, which is never derived from this attribution.

diff --git a/AGENTS.md b/AGENTS.md
index fd7722141..1c9e2b64c 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -428,6 +428,16 @@ unchanged.
a prefix of `routes`, and a substring check let a deleted section pass. The
corpus is rendered by `carlosframework/website`, which vendors a copy — so a
change here reaches the site only after that repo re-syncs and ships.
+- **A new CLI command, subcommand or console route declaration is not done
+ until `parity/parity.tsv` has its row.** This covers a new `carlos` command
+ or subcommand and a new `routeDecls` entry in
+ `internal/console/routedecls.go`; the row lands in the same branch. When a
+ branch closes a gap, move its row to `both`.
+ `TestParityTableCoversConsoleRoutes`, `TestParityCLITopLevel`,
+ `TestParityTableIsValid` and `TestParityPageIsCurrent` enforce this. Run
+ `make parity-doc` after editing the table. `TestParityCLITopLevel` checks
+ only top-level CLI commands against main.go. Keep subcommand rows by hand
+ until slice 4's registry.
- **Wire-shape changes are additive**: live pointers/manifests exist in
production buckets; anything written before your change must still parse.
- **Production channel names are pinned in tests**
diff --git a/docs/parity.md b/docs/parity.md
index 9f74455c9..d05318d82 100644
--- a/docs/parity.md
+++ b/docs/parity.md
@@ -1,12 +1,12 @@
# CLI and console parity
-This page is generated from `parity/parity.tsv` and `parity/packages.tsv` by `make parity-doc`. Edit the table, then regenerate the page.
+This page is generated from `parity/parity.tsv` and `parity/packages.tsv` by `make parity-doc`. Edit those files, then run `make parity-doc`.
## Counts
-Customer rows only. Rows outside customer parity are listed at the end.
+Only customer rows are counted. Rows outside customer parity appear at the end.
-Commands below the top level are checked for shape only until slice 4's registry.
+Only top-level CLI commands are checked against main.go. Subcommand rows stay hand-maintained until slice 4's registry.
| Status | Rows |
|---|---:|
@@ -254,7 +254,7 @@ Commands below the top level are checked for shape only until slice 4's registry
### wp-instances: Instances in the console: create, delete, channel, environment, assets, steering and region moves
-No discussion filed yet.
+Discussion #734.
- `instances-enable` (instances), CLI has `instances enable`
- `instances-create` (instances), CLI has `instances create [host, channel, environment, region, role, --from, --at, --restore]`
@@ -270,7 +270,7 @@ No discussion filed yet.
### wp-settings: Small settings forms over existing CLI doors
-No discussion filed yet.
+Discussion #735.
- `apps-build-probe` (apps), CLI has `apps build-probe`
- `apps-interactive` (apps), CLI has `apps set [--interactive]`
@@ -297,7 +297,7 @@ No discussion filed yet.
### wp-schedules-sidecars: Schedules and sidecars in the console
-No discussion filed yet.
+Discussion #736.
- `schedule` (schedules), CLI has `schedule ls`, `schedule set`, `schedule rm`, `schedule run`
- `sidecars` (sidecars), CLI has `sidecars enable`, `sidecars create`, `sidecars ls`, `sidecars wake`, `sidecars rm`, `sidecars logs`
@@ -306,7 +306,7 @@ No discussion filed yet.
### wp-email-storage: Email and storage self-serve in the console
-No discussion filed yet.
+Discussion #737.
- `store-create` (storage), CLI has `store create`
- `store-rotate` (storage), CLI has `store rotate`
@@ -322,7 +322,7 @@ No discussion filed yet.
### wp-cli-verbs: CLI verbs for console-only actions: team, activity, rename and account defaults
-No discussion filed yet.
+Discussion #738.
- `apps-rename` (apps), console has `POST /a/{sqid}/apps/{app}/rename`
- `apps-control-plane-set` (apps), console has `POST /a/{sqid}/apps/{app}/control-plane/set`
@@ -340,7 +340,7 @@ No discussion filed yet.
### wp-fleets-relay: Fleets and relay self-serve in the console
-No discussion filed yet.
+Discussion #739.
- `relay` (relay), CLI has `relay enable`, `relay status`, `relay disable`, `relay adopted`
- `fleets-create-byo` (fleets), CLI has `fleets create [--bucket]`
@@ -354,7 +354,7 @@ No discussion filed yet.
### wp-db-run: Database query and pull, non-interactive run, and door keys in the console
-No discussion filed yet.
+Discussion #740.
- `run` (data), CLI has `run [without -it]`
- `db-query` (data), CLI has `db query`
@@ -365,7 +365,7 @@ No discussion filed yet.
### wp-terminal: A browser terminal for run -it and console
-No discussion filed yet.
+Discussion #741.
- `run-interactive` (data), CLI has `run [-it]`, `console`
@@ -373,7 +373,7 @@ No discussion filed yet.
### wp-import: Instance import through the console
-No discussion filed yet.
+Discussion #742.
- `instances-import` (data), CLI has `instances import`, `instances import commit`, `instances import abort`
diff --git a/internal/parity/page.go b/internal/parity/page.go
index 3f2c692fd..947180407 100644
--- a/internal/parity/page.go
+++ b/internal/parity/page.go
@@ -14,7 +14,7 @@ func Render(rows []Row, pkgs []Package) []byte {
p := func(format string, args ...any) { fmt.Fprintf(&b, format, args...) }
p("# CLI and console parity\n\n")
- p("This page is generated from `parity/parity.tsv` and `parity/packages.tsv` by `make parity-doc`. Edit the table, then regenerate the page.\n\n")
+ p("This page is generated from `parity/parity.tsv` and `parity/packages.tsv` by `make parity-doc`. Edit those files, then run `make parity-doc`.\n\n")
// Counts, customer rows only.
counts := map[Status]int{}
@@ -26,8 +26,8 @@ func Render(rows []Row, pkgs []Package) []byte {
}
}
p("## Counts\n\n")
- p("Customer rows only. Rows outside customer parity are listed at the end.\n\n")
- p("Commands below the top level are checked for shape only until slice 4's registry.\n\n")
+ p("Only customer rows are counted. Rows outside customer parity appear at the end.\n\n")
+ p("Only top-level CLI commands are checked against main.go. Subcommand rows stay hand-maintained until slice 4's registry.\n\n")
p("| Status | Rows |\n|---|---:|\n")
for _, s := range customerStatuses {
p("| %s | %d |\n", s, counts[s])
@@ -75,7 +75,7 @@ func Render(rows []Row, pkgs []Package) []byte {
}
}
if len(gaps) == 0 {
- p("No gap rows name this package.\n")
+ p("No gap rows are assigned to this package.\n")
continue
}
for _, r := range gaps {
diff --git a/internal/parity/page_test.go b/internal/parity/page_test.go
index 9fb418069..d66ad65af 100644
--- a/internal/parity/page_test.go
+++ b/internal/parity/page_test.go
@@ -46,7 +46,7 @@ func TestRenderCountsCustomerOnly(t *testing.T) {
if strings.Contains(counts, "auth") || strings.Contains(counts, "internal") {
t.Errorf("counts include a non-customer status:\n%s", counts)
}
- line := "Commands below the top level are checked for shape only until slice 4's registry."
+ line := "Only top-level CLI commands are checked against main.go. Subcommand rows stay hand-maintained until slice 4's registry."
i, j := strings.Index(counts, line), strings.Index(counts, "| Status |")
if i < 0 || j < 0 || i > j {
t.Errorf("the slice 4 line is not above the counts table:\n%s", counts)
diff --git a/internal/parity/repo_test.go b/internal/parity/repo_test.go
index eae8df51a..20065fecb 100644
--- a/internal/parity/repo_test.go
+++ b/internal/parity/repo_test.go
@@ -99,3 +99,18 @@ func TestParityPageIsCurrent(t *testing.T) {
t.Error("docs/parity.md is stale: run make parity-doc")
}
}
+
+// TestParityPackagesFiled holds every work package to an amadan
+// discussion: a package with no discussion number is work nobody can
+// pick up.
+func TestParityPackagesFiled(t *testing.T) {
+ _, pkgs := loadRepo(t)
+ if len(pkgs) == 0 {
+ t.Fatal("parity/packages.tsv lists no packages")
+ }
+ for _, p := range pkgs {
+ if p.Discussion == 0 {
+ t.Errorf("parity/packages.tsv:%d: package %s has no discussion number: file it with amadan discuss new and record the number", p.Line, p.ID)
+ }
+ }
+}
diff --git a/parity/packages.tsv b/parity/packages.tsv
index 329153fb6..c74480b03 100644
--- a/parity/packages.tsv
+++ b/parity/packages.tsv
@@ -1,12 +1,12 @@
# Work packages that close gap rows in parity/parity.tsv. discussion is the
# amadan discussion number, empty until it is filed.
id title discussion
-wp-instances Instances in the console: create, delete, channel, environment, assets, steering and region moves
-wp-settings Small settings forms over existing CLI doors
-wp-schedules-sidecars Schedules and sidecars in the console
-wp-email-storage Email and storage self-serve in the console
-wp-cli-verbs CLI verbs for console-only actions: team, activity, rename and account defaults
-wp-fleets-relay Fleets and relay self-serve in the console
-wp-db-run Database query and pull, non-interactive run, and door keys in the console
-wp-terminal A browser terminal for run -it and console
-wp-import Instance import through the console
+wp-instances Instances in the console: create, delete, channel, environment, assets, steering and region moves 734
+wp-settings Small settings forms over existing CLI doors 735
+wp-schedules-sidecars Schedules and sidecars in the console 736
+wp-email-storage Email and storage self-serve in the console 737
+wp-cli-verbs CLI verbs for console-only actions: team, activity, rename and account defaults 738
+wp-fleets-relay Fleets and relay self-serve in the console 739
+wp-db-run Database query and pull, non-interactive run, and door keys in the console 740
+wp-terminal A browser terminal for run -it and console 741
+wp-import Instance import through the console 742