Skip to content

docs(canonical): add contract surface ERRORS.md, EVENTS.md, and sync-docs manifest - #34

Open
jdjioe5-cpu wants to merge 1 commit into
Kinlock-Org:mainfrom
jdjioe5-cpu:docs/canonical-contract-surface
Open

jdjioe5-cpu wants to merge 1 commit into
Kinlock-Org:mainfrom
jdjioe5-cpu:docs/canonical-contract-surface

Conversation

@jdjioe5-cpu

Copy link
Copy Markdown

Summary

Companion to Kinlock-Org/kinlock-contracts#34 (Roadmap row \M1-39, closes contracts #29).

This PR introduces the canonical versions of the contract surface reference documentation:

  • **\docs/ERRORS.md**: Canonical reference for all 32 active #[contracterror]\ codes across registry and vault, caller recovery instructions, lock terminality flags, and notes on retired codes 1 and 27.
  • **\docs/EVENTS.md**: Canonical specification for all 7 contract events across registry and vault with \schema_version = 1, precise field types, stroops integer unit explanations, and the rationale for immutable payout snapshots (Hard rule 2).
  • **\scripts/sync-docs.sh**: Updated \DOCS\ array to include \ERRORS.md\ and \EVENTS.md\ for automated synchronization into code repositories.
  • **\docs/ARCHITECTURE_ESSENTIALS.md**: Added quick-reference links to \ERRORS.md\ and \EVENTS.md.

Verification

  • Doc counts match contracts codebase: 32 error variants in \�rrors.rs\ vs 32 sections in \docs/ERRORS.md; 7 structs in \�vents.rs\ vs 7 sections in \docs/EVENTS.md.
  • Tested synchronization with \kinlock-contracts\ via \scripts/sync-docs.sh.

…docs manifest

- Add canonical docs/ERRORS.md covering all 32 active #[contracterror] codes with trigger conditions, caller guidance, and retired codes
- Add canonical docs/EVENTS.md covering all 7 contract events with schema_version = 1, stroops scale, and payout snapshotting rationale
- Update scripts/sync-docs.sh to sync ERRORS.md and EVENTS.md across code repositories
- Reference ERRORS.md and EVENTS.md in docs/ARCHITECTURE_ESSENTIALS.md
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.

2 participants