Skip to content

docs(process): add contract registry and milestone design-review gate (#115) - #116

Merged
tetsuh merged 9 commits into
mainfrom
docs/115-contract-registry
Jul 22, 2026
Merged

docs(process): add contract registry and milestone design-review gate (#115)#116
tetsuh merged 9 commits into
mainfrom
docs/115-contract-registry

Conversation

@tetsuh

@tetsuh tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner

Summary

  • add docs/08_contract_registry.md: an index of every wire surface and stable identifier, tracked
    along three axes (Contract status / Implementation status / single Design authority), with rules
    making registration happen at issue review and an overlapping-purpose second surface require an ADR
  • add docs/development_workflow.md §7: a milestone design-review gate (shared-mechanism inventory
    with a scoped trigger, registry check, dependency-substrate annotation, new-consumer intake,
    planned-not-normative banner) with explicit completion/re-scope criteria
  • wire registry Rule 2 into the ADR trigger (docs/10 §6) and the PR template
  • register the new document in the docs/00_overview.md document map

Closes #115

Issue #115 checklist (finalized — see the reviewed-rules addendum on #115)

  • docs/08_contract_registry.md: wire-surface and stable-identifier tables, each row carrying
    Contract status, Implementation status, Normative spec, a single Design authority, and
    implementers/consumers separately
  • Registry rules: new surfaces registered as Planned rows at issue/proposal review or milestone
    assembly; overlapping-purpose second surface requires an ADR (wired into docs/10 §6 and the
    PR template); a Planned row has exactly one authority and becomes Normative only when its
    owning ADR is Accepted; the registry is an index, not a spec
  • docs/development_workflow.md §7 (scoped shared-mechanism trigger, registry check with in-gate
    registration, dependency substrate annotation, new-consumer intake, planned-not-normative
    banner, gate completion + re-scope criteria)
  • docs/00_overview.md §5: registry added to the document map

Notes for review

  • Requirement IDs: none apply (process documentation; no F/N/C/P/X behavior changes).
  • ADR judgment: not required — this adds process rules and an index document; it makes no
    architecture decision and changes no contract. Registry Rule 2 is now itself an ADR trigger, but
    this PR introduces no overlapping surface.
  • RED-phase / AC-test logs: N/A — documentation-only, exempt from production-code TDD under §3.
  • Branch prefix is docs/ here; the convention (now clarified in §1) fixes it to feat/ going
    forward. Left as-is per owner decision; not renamed.
  • Workflow §7 is appended after §6 so existing section references (§2.1, §3) keep their numbers.

Inventory verification (registry rows → source of truth)

Row group Verified against
Key-space path grammar / op-to-key / query semantics src/key.cpp, 03 §1/§3/§4
Payload v1 / Encoding normalization / Batch v1 ParamValue codec, 03 §2.1/§2.2/§5
meta/session reply StorageNode meta route, 03 §7.1
buffers/<sid> (Normative, impl Planned) ADR-0014 Accepted (2026-07-09), #56 pending
Session-id / meta/ack parser grammar src/key.cpp IsValidSessionId / IsValidAckUuid
Status / Python exceptions (implemented rows only) 04 §1.1, 05 §2.1
Planned (ack / fence / UUIDv4 / OutcomeUnknown / #107 / #108×2) single authorities #114 / #106 / #107 / #108

Verification

  • All relative links and referenced section numbers verified against the tree
    (03 §1/§2.1/§2.2/§3/§4/§5/§6/§7.1, 04 §1.1, 05 §2.1, ADR-0014, 10 §6).
  • git diff --check passes; SonarCloud quality gate passes.

🤖 Generated with Claude Code

tetsuh and others added 2 commits July 22, 2026 23:45
- Add docs/08_contract_registry.md indexing wire surfaces and stable identifiers
- Rows link to normative specs only; the registry never restates contract text
- Planned rows name their design authority (#114 pending, #106 ADR, ADR-0014)
- Register the new document in the 00_overview document map

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Add workflow section 7: one breadth-first pass when a milestone is assembled
- 7.1 shared-mechanism inventory creates unifying design issues up front
- 7.2 checks new contract surfaces against the docs/08 registry
- 7.3 annotates cross-issue dependencies with their shared substrate and adds
  a new-consumer intake re-read
- 7.4 standardizes the planned-not-normative banner for forward-written specs
- Appended as section 7 so existing section references (2.1, 3) keep numbering

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 12 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8792ee21-f143-4efc-9c85-5a7bf737dcb5

📥 Commits

Reviewing files that changed from the base of the PR and between ddf4bb7 and bdd1bbf.

📒 Files selected for processing (3)
  • .github/pull_request_template.md
  • docs/08_contract_registry.md
  • docs/development_workflow.md
📝 Walkthrough

Walkthrough

Adds a public contract registry for wire surfaces and stable identifiers, documents its governance rules, adds a milestone design-review gate, and integrates registry checks into ADR and pull-request workflows.

Changes

Contract governance documentation

Layer / File(s) Summary
Contract registry definition
docs/08_contract_registry.md, docs/00_overview.md
Adds registry governance, wire-surface and stable-identifier tables, and the registry entry in the public document map.
Milestone design-review workflow
docs/development_workflow.md
Clarifies branch naming and issue/PR registry checklists, then adds the milestone review gate covering shared mechanisms, contract surfaces, dependencies, intake updates, and planned specifications.
ADR and pull-request contract checks
docs/10_adr_process.md, .github/pull_request_template.md
Requires ADR consideration for overlapping registry surfaces and adds prompts for affected contract-registry rows.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

  • tetsuh/sitos#45: Both PRs update branching-name documentation in docs/development_workflow.md to require the feat/ prefix.
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning The PR also changes docs/10_adr_process.md and the PR template, which #115 marked as out of scope. Split the ADR-process and template edits into a separate PR unless #115 is expanded to include them.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed The registry, workflow gate, and overview updates align with #115's acceptance criteria.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title accurately summarizes the main change: adding a contract registry and milestone design-review gate.
Description check ✅ Passed The description covers the summary, issue closure, checklist, ADR decision, and verification notes, with only minor template deviations.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/115-contract-registry

Comment @coderabbitai help to get the list of available commands.

@tetsuh
tetsuh marked this pull request as ready for review July 22, 2026 14:53
@tetsuh tetsuh self-assigned this Jul 22, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/00_overview.md`:
- Around line 80-85: Update the “Public documents (00–08)” statement in the
overview to match the documents marked Public in the table, including
09_dependency_policy.md, 10_adr_process.md, and development_workflow.md, or
revise the table’s classifications so both references consistently describe the
same public-document scope.

In `@docs/08_contract_registry.md`:
- Around line 13-14: Clarify Rule 1 in docs/08_contract_registry.md by defining
the required pre-implementation workflow for genuinely new wire surfaces or
stable identifiers: specify whether authors must add a Planned registry row
before issue review or reference a proposed row, and ensure the rule
consistently applies before the implementing PR updates that row.
- Line 36: Update the acknowledgment entry in the contract registry table to
explicitly distinguish ownership: reference Issue `#14` for transport
acknowledgment details, Issue `#17` for ParamStore policy, and Proposal `#114/its`
ADR only for the remaining design decisions. Ensure the linked authority
references consistently direct implementers to the correct owner.
- Around line 17-20: Clarify rule 3 in docs/08_contract_registry.md by defining
how a proposal Issue transfers authority to its resulting ADR and identifying
the exact Accepted status event that makes planned contract details normative.
Align this wording with the §7.4 ownership model, while ensuring planned rows
remain tentative before that acceptance and cannot remain indefinitely without a
completed handoff.

In `@docs/development_workflow.md`:
- Around line 169-171: Update the milestone design review gate in
docs/development_workflow.md to require coverage of §7.1–§7.4, including the
planned-contract banner check defined in §7.4, before milestone issue
implementation begins.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e75e762c-10bb-45d4-9715-936b3291b311

📥 Commits

Reviewing files that changed from the base of the PR and between 0b61249 and 0a4ca64.

📒 Files selected for processing (3)
  • docs/00_overview.md
  • docs/08_contract_registry.md
  • docs/development_workflow.md

Comment thread docs/00_overview.md Outdated
Comment thread docs/08_contract_registry.md Outdated
Comment thread docs/08_contract_registry.md Outdated
Comment thread docs/08_contract_registry.md Outdated
Comment thread docs/development_workflow.md
@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Review verdict: fix before merge

The overall mechanism is valuable, the diff is documentation-only and focused, relative links resolve, git diff --check passes, and the current CI checks are green. I found several contract/process inconsistencies that should be corrected before merge.

1. New-surface registration happens too late

docs/08_contract_registry.md Rule 1 requires an Issue that adds a surface to reference the affected row, but says the implementing PR updates the row. A new surface has no row to reference. docs/development_workflow.md §7.2 also checks the registry without requiring an unregistered surface to be added as a Planned row during that gate.

This defeats the early-detection goal: overlapping Issues can both observe “no row” and continue until an implementation PR.

Smallest fix: require a new Planned row during Issue/Proposal review or milestone assembly, before implementation starts. The implementation PR should advance its implementation state rather than perform first registration. Add Contract registry: <row> / N/A to the required Issue/PR review fields.

2. The registry conflates contract maturity and implementation state

docs/08_contract_registry.md marks buffers/<sid>/** as Planned, not normative, but ADR-0014 is already Accepted and its buffer contract is normative; only #56 implementation is pending.

Smallest fix: split the current Status column into:

  • Contract status: Planned / Normative
  • Implementation status: Planned / Implemented

Then represent buffers as Normative + Planned implementation.

3. ACK identifier maturity is internally inconsistent

The stable-identifier table combines session ID and ACK UUID grammar as Normative, implemented, while docs/03_wire_protocol.md §6 explicitly leaves ACK UUID representation/grammar to #14/#114. Section 1 documents <sid> but does not define <uuid>.

There are also two distinct contracts:

Smallest fix: split session ID, accepted ACK-route ID grammar, and generated correlation-ID format into separate rows. Either document the current parser grammar normatively in docs/03 §1 or mark it appropriately; keep generated UUIDv4 as Planned under #114 → ADR.

4. Planned identifiers are mixed into normative rows

The normative implemented Status and Python-exception rows contain planned names (OutcomeUnknown, OutcomeUnknownError) from a Proposal that is not yet accepted. Planned cross-language identifiers from #107 (FenceDurability/FenceReceipt) and the typed unavailable/state-lost results owned by #108 are absent.

Smallest fix: keep current implemented identifiers in normative rows and add separate Planned rows, with their Issue/ADR design authority. Names that remain undecided can be described generically without inventing final enum values.

5. The initial inventory is incomplete

The registry says it covers everything observable by another process over Zenoh, but has no row for:

  • operation-to-key mappings in docs/03 §3;
  • exact Get/List, zero-reply, wildcard, read-only, and unknown-session semantics in §4;
  • Encoding normalization, legacy spelling, and absent/unknown-Encoding fallback in §2.2.

These are implemented, externally observable contracts and are likely overlap points for future query or discovery mechanisms.

Smallest fix: add rows at a useful semantic granularity and include an inventory table in the PR verification mapping implemented routes/codecs and planned Issues to registry rows. The Issue #115 checklist should also be copied into the PR body with completed items, as required by the repository workflow.

6. The shared-mechanism trigger is over-broad

docs/development_workflow.md §7.1 requires a new unifying design Issue for any mechanism appearing in two or more Issues. This also catches existing Result handling, logging, timeouts, or a mechanism already governed by an Accepted ADR.

Smallest fix: limit the trigger to a new, unresolved, or materially changed cross-component mechanism used by two or more Issues and lacking an existing contract owner. If an existing owner/ADR applies, the review should reference it instead of creating a redundant Issue.

7. Gate completion and re-scope timing need clarification

The gate currently requires only posting a review artifact; it does not require an accepted outcome or disposition of findings. “Materially re-scoped” can also occur after some milestone implementation has started, making the current “before implementation of the milestone's Issues begins” wording impossible.

Smallest fix: require findings, follow-up ownership, and maintainer/owner acceptance. For re-scope, rerun the gate before added/changed scope begins and pause only affected work. Cover §7.1–§7.4.

Minor consistency fixes

  • The registry says rows never restate layouts, grammars, or values, but several rows do. Prefer: “row summaries are non-normative; linked specifications are authoritative; the registry owns inventory, maturity, implementation status, and design authority.”
  • docs/00_overview.md labels 09, 10, and development_workflow.md Public in the map but says only 00–08 are public documents. Align that sentence with the map.

No project files or GitHub relationships were modified by this review.

tetsuh and others added 2 commits July 23, 2026 00:32
- Split the registry Status column into Contract status, Implementation
  status, and Design authority so a normative-by-ADR contract with pending
  code (buffers/<sid>, ADR-0014 Accepted) is no longer mislabeled Planned
- Split session-id, accepted meta/ack route grammar (implemented, lenient),
  and generated UUIDv4 correlation-id (planned #114) into separate rows
- Move planned identifiers (OutcomeUnknown, OutcomeUnknownError) out of the
  normative rows; add planned rows for #107 fence identifiers and #108
  state-lost result
- Add rows for op-to-key mapping (03 §3), query semantics (03 §4), and
  Encoding normalization (03 §2.2)
- Route the ack surface authority to current owners #14/#17 with #114 as a
  pending consolidation proposal, not a settled authority
- Reframe the never-restate claim: row cells are non-normative summaries;
  linked specs are authoritative
- Fix the overview public-document sentence to match the document map

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Register new surfaces at issue/proposal review or milestone assembly
  (registry Rule 1) instead of at first implementation PR, so overlapping
  issues cannot both observe no row and proceed
- Scope the 7.1 unifying-issue trigger to new, unresolved, or materially
  changed cross-component mechanisms lacking an existing contract owner
- Require the gate to cover 7.1-7.4 and to complete only with recorded
  findings, follow-up owners, and owner acceptance; rerun on material
  re-scope, pausing only affected work
- Add the affected contract-registry row(s) to the required Issue fields
  and the PR template

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Review response — updated by Opus

Thanks — the reviews caught genuine design flaws, and there is a fair irony that a contract-registry
PR carried contract-maturity inconsistencies. I verified each finding independently against main
(ADR-0014 is Accepted; IsValidAckUuid/IsValidSessionId exist in src/key.cpp; docs/03 §6
routes ack finalization to #14/#17) and applied essentially all of them. Commits b20a2bc and
c64f259 on this branch.

Root cause and fix

The core defect (Sol #2/#3/#4) was one thing: the single Status column mashed three orthogonal
axes. It is now split into Contract status / Implementation status / Design authority,
which resolves all three at once.

Disposition

Sol findings

  1. New-surface registration too late — fixed. Registry Rule 1 now registers a Planned row at
    issue/proposal review or milestone assembly; the implementation PR advances the row rather than
    performing first registration. §7.2 states first registration happens in the gate. Added the
    affected registry row to the required Issue fields (§2.1) and the PR template (§4).
  2. Maturity vs implementation conflation — fixed. Two-column split; buffers/<sid> is now
    Normative (ADR-0014 Accepted) + Implementation Planned (Session-scoped durable and ephemeral buffer routes (ADR-0032 replacement of ADR-0014) #56).
  3. ACK identifier maturity — fixed. Split into three rows: session-id grammar (Normative,
    implemented), accepted meta/ack route grammar (IsValidAckUuid, implemented de-facto, not yet
    documented normatively → [M2] Ack protocol #14/Proposal: unify acknowledged writes and BufferPublisher fences with typed AckResult #114), and generated UUIDv4 (Planned, Proposal: unify acknowledged writes and BufferPublisher fences with typed AckResult #114).
  4. Planned names in normative rows — fixed. OutcomeUnknown / OutcomeUnknownError moved to
    separate Planned rows; added planned rows for BufferPublisher: explicit applied and synced fences #107 (FenceDurability/FenceReceipt) and SessionController: durable session catalog and restart reconciliation #108
    (state-lost result).
  5. Incomplete inventory — fixed (at semantic granularity). Added rows for op-to-key mapping
    (03 §3), query semantics (03 §4), and Encoding normalization (03 §2.2); a row→source
    verification table is in the PR body. I kept granularity coarse deliberately to avoid a
    30-row explosion.
  6. Over-broad §7.1 trigger — fixed. Now limited to a new, unresolved, or materially changed
    cross-component mechanism lacking an existing contract owner; if an owner/ADR applies, reference
    it instead of creating a redundant issue.
  7. Gate completion / re-scope timing — fixed. The gate completes only with recorded findings,
    follow-up owners, and owner acceptance; a material re-scope reruns the gate before the added scope
    begins, pausing only affected work.
    • Minor 1 (never-restate self-contradiction): reframed — row cells are non-normative summaries,
      linked specs authoritative, registry owns inventory/maturity/impl/authority.
    • Minor 2 (00–08 vs map): the overview sentence now reads "All documents listed above are public
      and maintained under docs/".

CodeRabbit findings — B (registration timing) = Sol #1; C (Rule 3 handoff) fixed: a proposal
Issue must hand off to an ADR and the row becomes Normative only when that ADR is Accepted; D (ack
authority) fixed with #3/#4; E (§7.4 in gate) fixed — the gate now covers §7.1–§7.4; the 00-overview
inline = Minor 2.

One partial decline

The automated Description check flags missing Requirements IDs / AC logs / RED / ADR checkbox.
For a docs-only PR these are legitimately N/A and the body already states them as such (Requirement
IDs: none; ADR: not required; RED/AC: exempt under §3). The only real residue was copying the #115
checklist into the PR body — now done. I did not add production-code template fields that do not
apply to documentation.

Still docs-only; git diff --check and the SonarCloud gate pass.

- Clarify that the branch prefix is always feat/; change type lives on the
  issue label and commit message, so the branch name does not repeat it
- Prevents inferring type-based prefixes from the commit-type list

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Re-review verdict: fix before merge

Reviewed at head 6cac026. The revision resolves most of the previous findings: early Planned-row registration, separate contract/implementation axes, the broader initial inventory, the narrowed shared-mechanism trigger, and explicit gate completion/re-scope rules are all materially improved. git diff --check passes and the PR is mergeable; three packaging/wheel checks are still pending at the time of this review.

A few contract/process inconsistencies remain.

1. Issue #115 still defines the old scope

The Issue body still says that the implementation PR first adds/updates a row, uses one normative/planned status axis, and creates a unifying design Issue for any mechanism shared by two or more Issues. The PR now intentionally implements different rules: pre-implementation Planned registration, independent contract/implementation axes, and a scoped ownerless-cross-component trigger.

This conflicts with docs/development_workflow.md's own rule that the Issue checklist is the definitive scope.

Smallest fix: update Issue #115's Scope and Acceptance Criteria to the reviewed rules, then copy that finalized checklist into the PR body.

2. The required field is not present in the actual PR template

docs/development_workflow.md:128-134 now requires Affected contract-registry row(s) advanced, or N/A in the PR template, but .github/pull_request_template.md was not changed and contains no such field.

Smallest fix: add an Affected contract-registry row(s) advanced, or N/A section to .github/pull_request_template.md.

3. The registry violates its own single-authority model

docs/08_contract_registry.md:14,29-31 defines one Issue or ADR as the design authority, but Planned rows currently mix multiple authorities, implementers, and consumers:

  • ACK: #14, #17, and #114;
  • Fence marker: #106, #99, and #107;
  • Fence result identifiers: #107, #106, and #114.

Normative rows also place implementation locations such as src/key.cpp, ParamStore, and StorageNode routing in the Design authority column. This makes the ownership axis ambiguous.

Smallest fix: give each Planned row exactly one authority (#114 → ADR for the shared ACK result, #106 → ADR for the marker, ADR-0014 for the buffer contract) and move implementation owners/consumers into a separate column or note. Also make the ADR/registry PR advance Contract status when the ADR becomes Accepted; the implementation PR should advance only Implementation status.

4. Key-space and ACK rows overlap ambiguously

The key-space row marks meta/** as Normative/Implemented while the ACK row marks meta/ack/<uuid> as Planned/Planned. This can be made consistent if the first row is only about already specified path grammar and the second is about ACK route behavior, but the current summaries do not state that boundary. Similarly, Accepted meta/ack/<uuid> route id grammar is labeled “Accepted” while its Contract status is Planned.

Smallest fix: scope the first row to explicit implemented path grammar, separate parser grammar from ACK route behavior, and rename the de-facto parser row without “Accepted.”

5. The #108 planned-result inventory is incomplete

The registry includes only Session unavailable / state-lost read result. Issue #108 separately requires typed catalog-unavailable behavior, which is another planned stable cross-component result.

Smallest fix: register the state-lost and catalog-unavailable results separately (or use one clearly scoped #108 row that explicitly includes both) under one authority.

6. Registry Rule 2 is not connected to the ADR decision flow

Registry Rule 2 requires an ADR for a second overlapping-purpose surface, while the PR checklist still asks only whether docs/10_adr_process.md §6 applies. A non-breaking additive stable identifier can trigger Rule 2 without clearly triggering §6.

Smallest fix: change the workflow and PR-template ADR field to check docs/10 §6 or registry Rule 2. Preferably add the same trigger to docs/10_adr_process.md §6 so ADR requirements have one consistent entry point.

Once these are corrected and the remaining checks pass, the mechanism should be ready to merge.

tetsuh and others added 2 commits July 23, 2026 01:06
- Give every Planned row exactly one design authority; settled normative
  rows use '—' and list implementers/consumers in a separate column
- Move src/key.cpp, ParamStore, and StorageNode routing out of the authority
  column into Implementer / consumers
- Scope the key-space row to path grammar (meta/** route shapes) and the ack
  row to route behavior so the two no longer overlap ambiguously
- Rename the lenient meta/ack parser-grammar row to drop 'Accepted', which
  collided with the Contract-status wording
- Register the #108 typed catalog-unavailable result alongside the state-lost
  read result

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ate (#115)

- Add the Contract Registry field to .github/pull_request_template.md so the
  required section documented in workflow §4 exists in the actual template
- Add registry Rule 2 (overlapping surface) as an ADR trigger in docs/10 §6,
  giving ADR requirements one consistent entry point
- Reference '§6 or registry Rule 2' in the workflow §4 ADR field and the PR
  template ADR section

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Re-review response — updated by Opus

All six re-review findings applied (head now ddf4bb7, commits 6e0f025 and ddf4bb7; the
branch-prefix clarification is 6cac026). I verified the two points that needed checking:
.github/pull_request_template.md exists and enumerates the fields (so #2 was a real gap), and
docs/10 §6 has a concrete trigger list to extend (#6).

Disposition

  1. Issue Docs: add public contract registry and milestone design-review gate #115 scope drift — reconciled. Rather than silently rewriting the filed body (which
    §5 discourages), I posted a reviewed-rules addendum on Docs: add public contract registry and milestone design-review gate #115 recording the finalized rules
    (pre-implementation registration, three axes, scoped trigger, single authority, Rule 2 wiring) and
    copied the finalized checklist into this PR body. Same outcome as "update Scope/AC", done as a
    recorded addendum to respect §5.
  2. PR template field missing — fixed. Added a Contract Registry section to
    .github/pull_request_template.md (the file existed with the other fields; only the doc §4 listed
    the new one).
  3. Single-authority violation — fixed. Every Planned row now has exactly one Design authority
    (#114 → ADR for the ACK result, #106 → ADR for the marker, ADR-0014 for buffers, #107/
    #108 for their identifiers). Implementers and consumers (src/key.cpp, ParamStore, StorageNode
    routing, consuming issues) moved to a separate Implementer / consumers column; settled normative
    rows use for authority. The ADR-lands-Contract-status / impl-PR-lands-Implementation-status
    split is stated in Rule 1.
  4. Key-space / ACK overlap and "Accepted" wording — fixed. The key-space row is scoped to
    path grammar (meta/** route shapes) and the ACK row to route behavior, so they no longer
    overlap. The lenient parser-grammar identifier row dropped "Accepted" (it collided with the
    Contract-status wording) and is now "meta/ack/<uuid> route id grammar (lenient parser,
    IsValidAckUuid)".
  5. SessionController: durable session catalog and restart reconciliation #108 inventory — completed. Registered the typed catalog-unavailable result (catalog
    corruption fail-closed) as a separate SessionController: durable session catalog and restart reconciliation #108 row alongside the state-lost read result, both under
    #108 → ADR.
  6. Rule 2 ↔ ADR flow — connected. Registry Rule 2 is now an explicit ADR trigger in
    docs/10 §6, and both the workflow §4 ADR field and the PR template ADR section read
    "§6 or registry Rule 2", giving one consistent entry point.

Still docs-only; git diff --check passes and no source/CI behavior changes. Ready for a final look.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/pull_request_template.md:
- Around line 9-12: Update the Contract Registry prompt in the pull request
template to require authors to list all affected contract-registry rows and
explicitly state the status transition: Implementation, Contract, or none. Do
not limit the request to rows that advanced, so changes with no registry status
update still report affected rows and the applicable authority.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: de030263-7c25-4492-a6fe-188ab4b4f0df

📥 Commits

Reviewing files that changed from the base of the PR and between 6cac026 and ddf4bb7.

📒 Files selected for processing (4)
  • .github/pull_request_template.md
  • docs/08_contract_registry.md
  • docs/10_adr_process.md
  • docs/development_workflow.md
🚧 Files skipped from review as they are similar to previous changes (2)
  • docs/08_contract_registry.md
  • docs/development_workflow.md

Comment thread .github/pull_request_template.md
- The meta/ack route-id-grammar row listed two design authorities (#14/#114);
  set it to #114 to match the ack wire-surface row and record #14 as the
  current owner in notes, satisfying the one-authority rule
- Remove the redundant '§6 or Rule 2' phrasing now that registry Rule 2 is a
  trigger inside docs/10 §6; §4 and the PR template point at §6 as the single
  ADR-trigger source

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Review — FIX BEFORE MERGE

Findings

  1. Major.github/pull_request_template.md:11 and docs/development_workflow.md:137 require only rows that were "advanced". However, docs/08_contract_registry.md:3-5,24-28 requires an affected-row reference even for contract changes without a status transition. This can let an existing-implementation correction be recorded as N/A, bypassing the early-detection gate. Require the affected row and the transition (Contract, Implementation, or none) as separate fields. Existing unresolved discussion: docs(process): add contract registry and milestone design-review gate (#115) #116 (comment)

  2. Majordocs/08_contract_registry.md:57 lists ADR-0014 as the Design authority for normative buffers/<sid>/**, while docs/08_contract_registry.md:14-16,43-44 defines settled normative contracts as having Design authority . ADR-0014 is already Accepted (docs/adr/0014-session-scoped-buffers.md:3-5). Change the Design authority to and retain the ADR link only in the Normative spec column.

  3. Majordocs/08_contract_registry.md:55,70 lists #114 → ADR as the Design authority for the ACK route/grammar, but docs/03_wire_protocol.md:206-211 identifies issue [M2] Ack protocol #14 as the current decision owner ([M2] ParamStore: ack / detailed error mapping #17 for ParamStore policy). Issue Proposal: unify acknowledged writes and BufferPublisher fences with typed AckResult #114 itself says it becomes authority only if accepted, and this PR scopes acceptance of Proposal: unify acknowledged writes and BufferPublisher fences with typed AckResult #114 out. Keep [M2] Ack protocol #14 as the current authority, note Proposal: unify acknowledged writes and BufferPublisher fences with typed AckResult #114 as a pending handoff, and update after ADR acceptance.

Validation

  • All 36 relative Markdown links in the five changed files resolve.
  • CI: 16 successful checks, 0 failures.
  • Documentation-only change; no additional tests are required.

- Track affected rows plus their status transition (Contract / Implementation /
  none) in §2.1, §4, and the PR template, so a contract change with no status
  transition is no longer reportable as N/A
- Set buffers/<sid> Design authority to '—' (settled normative per the intro
  rule); the ADR-0014 link stays in the Normative spec column
- Set both meta/ack rows' Design authority to '#14 → ADR' (the current owner per
  docs/03 §6), with #114 recorded as a pending consolidation rather than a
  pre-anticipated authority; #17 is the ParamStore policy consumer

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@sonarqubecloud

Copy link
Copy Markdown

@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Re-review response — updated by Opus

All three findings applied (head bdd1bbf). I re-verified each against the branch rather than from
memory before changing anything.

  1. Tracking field "advanced" gap — fixed. §2.1, §4, and .github/pull_request_template.md now
    ask for the affected row(s) plus their status transition (Contract / Implementation /
    none), with N/A reserved for "no contract is touched". This closes the case where a contract
    change with no status transition could be recorded as N/A, and it also removes the prior
    §2.1-vs-§4 wording inconsistency (§2.1 said "affected", §4/template said "advanced"). Resolves the
    CodeRabbit thread at r3631844982.
  2. buffers/<sid> authority — fixed. Set to , matching the intro rule that a settled
    normative contract has authority ; the ADR-0014 link remains only in the Normative spec column.
  3. ACK authority — fixed. Both meta/ack rows now name #14 → ADR (the current owner per
    docs/03 §6: "[M2] Ack protocol #14 must finalize … UUID grammar … [M2] ParamStore: ack / detailed error mapping #17 owns the ParamStore policy"), with #114
    recorded as a pending consolidation rather than a pre-anticipated authority, and #17 as the
    ParamStore-policy consumer.

On the ACK point specifically: I'm treating your two rounds as consistent, not contradictory — the
"exactly one authority" principle from the earlier round stands, and this round corrects only which
single owner it is. Recording an unaccepted proposal (#114) as the authority was the pre-anticipation
error I should have caught, since registry Rule 3 already says a proposal alone never confers
normative status; the fix aligns the rows with docs/03 §6 and #114's own "if accepted" wording.

Still docs-only; git diff --check passes.

@tetsuh

tetsuh commented Jul 22, 2026

Copy link
Copy Markdown
Owner Author

Re-review — MERGE

The current head (bdd1bbf2cdb63bd6c29ffbebeb8e3670eec396dc) resolves all prior findings. No new blocker, major, or minor issues found.

Resolved

Validation

  • All 36 relative Markdown links in the five changed files resolve.
  • Diff application and whitespace validation pass.
  • CI: 16 successful checks, 0 failures.

Note: when PR #117's ADR-0028 is eventually Accepted, update the related registry row's spec, status, and authority under Rule 1 introduced by this PR.

@tetsuh
tetsuh merged commit 785465b into main Jul 22, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs: add public contract registry and milestone design-review gate

1 participant